Class: LSP::TextDocumentWillSaveEvent
- Defined in:
- lib/lsp/lsp_types.rb
Overview
export interface TextDocumentWillSaveEvent
/**
* The document that will be saved
*/
document: TextDocument;
/**
* The reason why save was triggered.
*/
reason: 1 | 2 | 3;
Instance Attribute Summary collapse
-
#document ⇒ Object
type: TextDocument # type: 1 | 2 | 3.
-
#reason ⇒ Object
type: TextDocument # type: 1 | 2 | 3.
Instance Method Summary collapse
Methods inherited from LSPBase
Constructor Details
This class inherits a constructor from LSP::LSPBase
Instance Attribute Details
#document ⇒ Object
type: TextDocument # type: 1 | 2 | 3
1520 1521 1522 |
# File 'lib/lsp/lsp_types.rb', line 1520 def document @document end |
#reason ⇒ Object
type: TextDocument # type: 1 | 2 | 3
1520 1521 1522 |
# File 'lib/lsp/lsp_types.rb', line 1520 def reason @reason end |
Instance Method Details
#from_h!(value) ⇒ Object
1522 1523 1524 1525 1526 1527 |
# File 'lib/lsp/lsp_types.rb', line 1522 def from_h!(value) value = {} if value.nil? self.document = TextDocument.new(value['document']) unless value['document'].nil? self.reason = value['reason'] # Unknown type self end |