Sha256: d8cde524643cf24f2d99095f308bbfc8bc9dab82ec34f27d60a80e52a5403514
Contents?: true
Size: 1.23 KB
Versions: 6
Compression:
Stored size: 1.23 KB
Contents
module LanguageServer module Protocol module Interface class DocumentOnTypeFormattingParams def initialize(text_document:, position:, ch:, options:) @attributes = {} @attributes[:textDocument] = text_document @attributes[:position] = position @attributes[:ch] = ch @attributes[:options] = options @attributes.freeze end # # The document to format. # # @return [TextDocumentIdentifier] def text_document attributes.fetch(:textDocument) end # # The position at which this request was sent. # # @return [Position] def position attributes.fetch(:position) end # # The character that has been typed. # # @return [string] def ch attributes.fetch(:ch) end # # The format options. # # @return [FormattingOptions] def options attributes.fetch(:options) 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