class RubyLsp::Requests::DocumentHighlight
The document highlight informs the editor all relevant elements of the currently pointed item for highlighting. For example, when the cursor is on the F
of the constant FOO
, the editor should identify other occurrences of FOO
and highlight them.
For writable elements like constants or variables, their read/write occurrences should be highlighted differently. This is achieved by sending different “kind” attributes to the editor (2 for read and 3 for write).
Example¶ ↑
FOO = 1 # should be highlighted as "write" def foo FOO # should be highlighted as "read" end
Public Class Methods
new(document, position, dispatcher)
Calls superclass method