Class: LSP::DeclarationClientCapabilities

Inherits:
LSPBase
  • Object
show all
Defined in:
lib/lsp/lsp_protocol_declaration.rb

Overview

export interface DeclarationClientCapabilities

/**
 * Whether declaration supports dynamic registration. If this is set to `true`
 * the client supports the new `DeclarationRegistrationOptions` return value
 * for the corresponding server capability as well.
 */
dynamicRegistration?: boolean;
/**
 * The client supports additional metadata in the form of declaration links.
 */
linkSupport?: boolean;

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from LSPBase

#to_h, #to_json

Constructor Details

#initialize(initial_hash = nil) ⇒ DeclarationClientCapabilities

Returns a new instance of DeclarationClientCapabilities.



26
27
28
29
# File 'lib/lsp/lsp_protocol_declaration.rb', line 26

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

Instance Attribute Details

#dynamicRegistrationObject

type: boolean # type: boolean



24
25
26
# File 'lib/lsp/lsp_protocol_declaration.rb', line 24

def dynamicRegistration
  @dynamicRegistration
end

#linkSupportObject

type: boolean # type: boolean



24
25
26
# File 'lib/lsp/lsp_protocol_declaration.rb', line 24

def linkSupport
  @linkSupport
end

Instance Method Details

#from_h!(value) ⇒ Object



31
32
33
34
35
36
# File 'lib/lsp/lsp_protocol_declaration.rb', line 31

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