Class: LanguageServer::Protocol::Interface::CallHierarchyRegistrationOptions
- Inherits:
-
Object
- Object
- LanguageServer::Protocol::Interface::CallHierarchyRegistrationOptions
- Defined in:
- lib/language_server/protocol/interface/call_hierarchy_registration_options.rb,
sig/language_server/protocol/interface/call_hierarchy_registration_options.rbs
Overview
Call hierarchy options used during static or dynamic registration.
Instance Attribute Summary collapse
- #attributes ⇒ Hash[Symbol, untyped] readonly
Instance Method Summary collapse
-
#document_selector ⇒ DocumentSelector | nil
A document selector to identify the scope of the registration.
-
#id ⇒ string
The id used to register the request.
-
#initialize(document_selector:, work_done_progress: nil, id: nil) ⇒ CallHierarchyRegistrationOptions
constructor
A new instance of CallHierarchyRegistrationOptions.
- #to_hash ⇒ Hash[Symbol, untyped]
- #to_json(*args) ⇒ String
- #work_done_progress ⇒ boolean
Constructor Details
#initialize(document_selector:, work_done_progress: nil, id: nil) ⇒ CallHierarchyRegistrationOptions
Returns a new instance of CallHierarchyRegistrationOptions.
10 11 12 13 14 15 16 17 18 |
# File 'lib/language_server/protocol/interface/call_hierarchy_registration_options.rb', line 10 def initialize(document_selector:, work_done_progress: nil, id: nil) @attributes = {} @attributes[:documentSelector] = document_selector @attributes[:workDoneProgress] = work_done_progress if work_done_progress @attributes[:id] = id if id @attributes.freeze end |
Instance Attribute Details
#attributes ⇒ Hash[Symbol, untyped] (readonly)
43 44 45 |
# File 'lib/language_server/protocol/interface/call_hierarchy_registration_options.rb', line 43 def attributes @attributes end |
Instance Method Details
#document_selector ⇒ DocumentSelector | nil
A document selector to identify the scope of the registration. If set to null the document selector provided on the client side will be used.
25 26 27 |
# File 'lib/language_server/protocol/interface/call_hierarchy_registration_options.rb', line 25 def document_selector attributes.fetch(:documentSelector) end |
#id ⇒ string
The id used to register the request. The id can be used to deregister the request again. See also Registration#id.
39 40 41 |
# File 'lib/language_server/protocol/interface/call_hierarchy_registration_options.rb', line 39 def id attributes.fetch(:id) end |
#to_hash ⇒ Hash[Symbol, untyped]
45 46 47 |
# File 'lib/language_server/protocol/interface/call_hierarchy_registration_options.rb', line 45 def to_hash attributes end |
#to_json(*args) ⇒ String
49 50 51 |
# File 'lib/language_server/protocol/interface/call_hierarchy_registration_options.rb', line 49 def to_json(*args) to_hash.to_json(*args) end |
#work_done_progress ⇒ boolean
30 31 32 |
# File 'lib/language_server/protocol/interface/call_hierarchy_registration_options.rb', line 30 def work_done_progress attributes.fetch(:workDoneProgress) end |