Class: LSP::DocumentFormattingParams
- Defined in:
- lib/lsp/lsp_protocol.rb
Overview
export interface DocumentFormattingParams extends WorkDoneProgressParams
/**
* The document to format.
*/
textDocument: TextDocumentIdentifier;
/**
* The format options
*/
options: FormattingOptions;
Instance Attribute Summary collapse
-
#options ⇒ Object
type: TextDocumentIdentifier # type: FormattingOptions # type: ProgressToken.
-
#textDocument ⇒ Object
type: TextDocumentIdentifier # type: FormattingOptions # type: ProgressToken.
-
#workDoneToken ⇒ Object
type: TextDocumentIdentifier # type: FormattingOptions # type: ProgressToken.
Instance Method Summary collapse
- #from_h!(value) ⇒ Object
-
#initialize(initial_hash = nil) ⇒ DocumentFormattingParams
constructor
A new instance of DocumentFormattingParams.
Methods inherited from LSPBase
Constructor Details
#initialize(initial_hash = nil) ⇒ DocumentFormattingParams
Returns a new instance of DocumentFormattingParams.
2234 2235 2236 2237 |
# File 'lib/lsp/lsp_protocol.rb', line 2234 def initialize(initial_hash = nil) super @optional_method_names = %i[workDoneToken] end |
Instance Attribute Details
#options ⇒ Object
type: TextDocumentIdentifier # type: FormattingOptions # type: ProgressToken
2232 2233 2234 |
# File 'lib/lsp/lsp_protocol.rb', line 2232 def @options end |
#textDocument ⇒ Object
type: TextDocumentIdentifier # type: FormattingOptions # type: ProgressToken
2232 2233 2234 |
# File 'lib/lsp/lsp_protocol.rb', line 2232 def textDocument @textDocument end |
#workDoneToken ⇒ Object
type: TextDocumentIdentifier # type: FormattingOptions # type: ProgressToken
2232 2233 2234 |
# File 'lib/lsp/lsp_protocol.rb', line 2232 def workDoneToken @workDoneToken end |
Instance Method Details
#from_h!(value) ⇒ Object
2239 2240 2241 2242 2243 2244 2245 |
# File 'lib/lsp/lsp_protocol.rb', line 2239 def from_h!(value) value = {} if value.nil? self.textDocument = value['textDocument'] # Unknown type self. = value['options'] # Unknown type self.workDoneToken = value['workDoneToken'] # Unknown type self end |