Sha256: 84e8af3c2567a28642847d94c7f2192b855cc68cdf10ebadfd854091c08c2bf5
Contents?: true
Size: 1.12 KB
Versions: 6
Compression:
Stored size: 1.12 KB
Contents
module LanguageServer module Protocol module Interface # # Params for the CodeActionRequest # class CodeActionParams def initialize(text_document:, range:, context:) @attributes = {} @attributes[:textDocument] = text_document @attributes[:range] = range @attributes[:context] = context @attributes.freeze end # # The document in which the command was invoked. # # @return [TextDocumentIdentifier] def text_document attributes.fetch(:textDocument) end # # The range for which the command was invoked. # # @return [Range] def range attributes.fetch(:range) end # # Context carrying additional information. # # @return [CodeActionContext] def context attributes.fetch(:context) end attr_reader :attributes def to_hash attributes end def to_json(*args) to_hash.to_json(*args) end end end end end
Version data entries
6 entries across 6 versions & 1 rubygems