Class: Rucoa::Handlers::TextDocumentDocumentHighlightHandler::NodeToHighlightsMappers::ForMapper

Inherits:
Base
  • Object
show all
Defined in:
lib/rucoa/handlers/text_document_document_highlight_handler.rb

Instance Method Summary collapse

Methods inherited from Base

call, #initialize

Constructor Details

This class inherits a constructor from Rucoa::Handlers::TextDocumentDocumentHighlightHandler::NodeToHighlightsMappers::Base

Instance Method Details

#callArray

Returns:

  • (Array)


268
269
270
271
272
273
274
275
276
# File 'lib/rucoa/handlers/text_document_document_highlight_handler.rb', line 268

def call
  [
    @node.location.keyword,
    @node.location.in,
    @node.location.end
  ].compact.map do |parser_range|
    Highlights::TextHighlight.new(parser_range: parser_range)
  end
end