Class: LSP::SaveOptions

Inherits:
LSPBase show all
Defined in:
lib/lsp/lsp_protocol.rb

Overview

export interface SaveOptions

/**
 * The client is supposed to include the content on save.
 */
includeText?: boolean;

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from LSPBase

#to_h, #to_json

Constructor Details

#initialize(initial_hash = nil) ⇒ SaveOptions

Returns a new instance of SaveOptions.



203
204
205
206
# File 'lib/lsp/lsp_protocol.rb', line 203

def initialize(initial_hash = nil)
  super
  @optional_method_names = %i[includeText]
end

Instance Attribute Details

#includeTextObject

type: boolean



201
202
203
# File 'lib/lsp/lsp_protocol.rb', line 201

def includeText
  @includeText
end

Instance Method Details

#from_h!(value) ⇒ Object



208
209
210
211
212
# File 'lib/lsp/lsp_protocol.rb', line 208

def from_h!(value)
  value = {} if value.nil?
  self.includeText = value['includeText'] # Unknown type
  self
end