language_server-protocol 3.16.0.0 → 3.16.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (96) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +2 -0
  3. data/lib/language_server/protocol/interface/annotated_text_edit.rb +19 -1
  4. data/lib/language_server/protocol/interface/call_hierarchy_incoming_calls_params.rb +20 -2
  5. data/lib/language_server/protocol/interface/call_hierarchy_options.rb +6 -1
  6. data/lib/language_server/protocol/interface/call_hierarchy_outgoing_calls_params.rb +20 -2
  7. data/lib/language_server/protocol/interface/call_hierarchy_prepare_params.rb +28 -2
  8. data/lib/language_server/protocol/interface/call_hierarchy_registration_options.rb +27 -2
  9. data/lib/language_server/protocol/interface/code_action_options.rb +6 -1
  10. data/lib/language_server/protocol/interface/code_action_params.rb +20 -2
  11. data/lib/language_server/protocol/interface/code_action_registration_options.rb +37 -2
  12. data/lib/language_server/protocol/interface/code_lens_options.rb +6 -1
  13. data/lib/language_server/protocol/interface/code_lens_params.rb +20 -2
  14. data/lib/language_server/protocol/interface/code_lens_registration_options.rb +25 -2
  15. data/lib/language_server/protocol/interface/color_presentation_params.rb +20 -2
  16. data/lib/language_server/protocol/interface/completion_options.rb +6 -1
  17. data/lib/language_server/protocol/interface/completion_params.rb +38 -2
  18. data/lib/language_server/protocol/interface/completion_registration_options.rb +57 -2
  19. data/lib/language_server/protocol/interface/declaration_options.rb +6 -1
  20. data/lib/language_server/protocol/interface/declaration_params.rb +38 -2
  21. data/lib/language_server/protocol/interface/declaration_registration_options.rb +27 -2
  22. data/lib/language_server/protocol/interface/definition_options.rb +6 -1
  23. data/lib/language_server/protocol/interface/definition_params.rb +38 -2
  24. data/lib/language_server/protocol/interface/definition_registration_options.rb +17 -2
  25. data/lib/language_server/protocol/interface/document_color_options.rb +6 -1
  26. data/lib/language_server/protocol/interface/document_color_params.rb +20 -2
  27. data/lib/language_server/protocol/interface/document_color_registration_options.rb +27 -2
  28. data/lib/language_server/protocol/interface/document_formatting_options.rb +6 -1
  29. data/lib/language_server/protocol/interface/document_formatting_params.rb +9 -1
  30. data/lib/language_server/protocol/interface/document_formatting_registration_options.rb +17 -2
  31. data/lib/language_server/protocol/interface/document_highlight_options.rb +6 -1
  32. data/lib/language_server/protocol/interface/document_highlight_params.rb +38 -2
  33. data/lib/language_server/protocol/interface/document_highlight_registration_options.rb +17 -2
  34. data/lib/language_server/protocol/interface/document_link_options.rb +6 -1
  35. data/lib/language_server/protocol/interface/document_link_params.rb +20 -2
  36. data/lib/language_server/protocol/interface/document_link_registration_options.rb +25 -2
  37. data/lib/language_server/protocol/interface/document_on_type_formatting_params.rb +17 -1
  38. data/lib/language_server/protocol/interface/document_on_type_formatting_registration_options.rb +28 -2
  39. data/lib/language_server/protocol/interface/document_range_formatting_options.rb +6 -1
  40. data/lib/language_server/protocol/interface/document_range_formatting_params.rb +9 -1
  41. data/lib/language_server/protocol/interface/document_range_formatting_registration_options.rb +17 -2
  42. data/lib/language_server/protocol/interface/document_symbol_options.rb +6 -1
  43. data/lib/language_server/protocol/interface/document_symbol_params.rb +20 -2
  44. data/lib/language_server/protocol/interface/document_symbol_registration_options.rb +26 -2
  45. data/lib/language_server/protocol/interface/execute_command_options.rb +6 -1
  46. data/lib/language_server/protocol/interface/execute_command_params.rb +9 -1
  47. data/lib/language_server/protocol/interface/execute_command_registration_options.rb +14 -1
  48. data/lib/language_server/protocol/interface/folding_range_options.rb +6 -1
  49. data/lib/language_server/protocol/interface/folding_range_params.rb +20 -2
  50. data/lib/language_server/protocol/interface/folding_range_registration_options.rb +27 -2
  51. data/lib/language_server/protocol/interface/hover_options.rb +6 -1
  52. data/lib/language_server/protocol/interface/hover_params.rb +28 -2
  53. data/lib/language_server/protocol/interface/hover_registration_options.rb +17 -2
  54. data/lib/language_server/protocol/interface/implementation_options.rb +6 -1
  55. data/lib/language_server/protocol/interface/implementation_params.rb +38 -2
  56. data/lib/language_server/protocol/interface/implementation_registration_options.rb +27 -2
  57. data/lib/language_server/protocol/interface/initialize_params.rb +9 -1
  58. data/lib/language_server/protocol/interface/linked_editing_range_options.rb +6 -1
  59. data/lib/language_server/protocol/interface/linked_editing_range_params.rb +28 -2
  60. data/lib/language_server/protocol/interface/linked_editing_range_registration_options.rb +27 -2
  61. data/lib/language_server/protocol/interface/moniker_options.rb +6 -1
  62. data/lib/language_server/protocol/interface/moniker_params.rb +38 -2
  63. data/lib/language_server/protocol/interface/moniker_registration_options.rb +17 -2
  64. data/lib/language_server/protocol/interface/notification_message.rb +6 -1
  65. data/lib/language_server/protocol/interface/optional_versioned_text_document_identifier.rb +9 -1
  66. data/lib/language_server/protocol/interface/prepare_rename_params.rb +17 -1
  67. data/lib/language_server/protocol/interface/reference_options.rb +6 -1
  68. data/lib/language_server/protocol/interface/reference_params.rb +38 -2
  69. data/lib/language_server/protocol/interface/reference_registration_options.rb +17 -2
  70. data/lib/language_server/protocol/interface/rename_options.rb +6 -1
  71. data/lib/language_server/protocol/interface/rename_params.rb +28 -2
  72. data/lib/language_server/protocol/interface/rename_registration_options.rb +25 -2
  73. data/lib/language_server/protocol/interface/request_message.rb +6 -1
  74. data/lib/language_server/protocol/interface/response_message.rb +6 -1
  75. data/lib/language_server/protocol/interface/selection_range_options.rb +6 -1
  76. data/lib/language_server/protocol/interface/selection_range_params.rb +20 -2
  77. data/lib/language_server/protocol/interface/selection_range_registration_options.rb +27 -2
  78. data/lib/language_server/protocol/interface/semantic_tokens_delta_params.rb +20 -2
  79. data/lib/language_server/protocol/interface/semantic_tokens_options.rb +6 -1
  80. data/lib/language_server/protocol/interface/semantic_tokens_params.rb +20 -2
  81. data/lib/language_server/protocol/interface/semantic_tokens_range_params.rb +20 -2
  82. data/lib/language_server/protocol/interface/semantic_tokens_registration_options.rb +55 -2
  83. data/lib/language_server/protocol/interface/signature_help_options.rb +6 -1
  84. data/lib/language_server/protocol/interface/signature_help_params.rb +28 -2
  85. data/lib/language_server/protocol/interface/signature_help_registration_options.rb +38 -2
  86. data/lib/language_server/protocol/interface/text_document_change_registration_options.rb +10 -1
  87. data/lib/language_server/protocol/interface/text_document_save_registration_options.rb +10 -1
  88. data/lib/language_server/protocol/interface/type_definition_options.rb +6 -1
  89. data/lib/language_server/protocol/interface/type_definition_params.rb +38 -2
  90. data/lib/language_server/protocol/interface/type_definition_registration_options.rb +27 -2
  91. data/lib/language_server/protocol/interface/versioned_text_document_identifier.rb +9 -1
  92. data/lib/language_server/protocol/interface/workspace_symbol_options.rb +6 -1
  93. data/lib/language_server/protocol/interface/workspace_symbol_params.rb +20 -2
  94. data/lib/language_server/protocol/interface/workspace_symbol_registration_options.rb +6 -1
  95. data/lib/language_server/protocol/version.rb +1 -1
  96. metadata +3 -3
@@ -1,15 +1,40 @@
1
1
  module LanguageServer
2
2
  module Protocol
3
3
  module Interface
4
- class ImplementationRegistrationOptions < StaticRegistrationOptions
5
- def initialize(id: nil)
4
+ class ImplementationRegistrationOptions
5
+ def initialize(document_selector:, work_done_progress: nil, id: nil)
6
6
  @attributes = {}
7
7
 
8
+ @attributes[:documentSelector] = document_selector
9
+ @attributes[:workDoneProgress] = work_done_progress if work_done_progress
8
10
  @attributes[:id] = id if id
9
11
 
10
12
  @attributes.freeze
11
13
  end
12
14
 
15
+ #
16
+ # A document selector to identify the scope of the registration. If set to
17
+ # null the document selector provided on the client side will be used.
18
+ #
19
+ # @return [DocumentSelector]
20
+ def document_selector
21
+ attributes.fetch(:documentSelector)
22
+ end
23
+
24
+ # @return [boolean]
25
+ def work_done_progress
26
+ attributes.fetch(:workDoneProgress)
27
+ end
28
+
29
+ #
30
+ # The id used to register the request. The id can be used to deregister
31
+ # the request again. See also Registration#id.
32
+ #
33
+ # @return [string]
34
+ def id
35
+ attributes.fetch(:id)
36
+ end
37
+
13
38
  attr_reader :attributes
14
39
 
15
40
  def to_hash
@@ -1,7 +1,7 @@
1
1
  module LanguageServer
2
2
  module Protocol
3
3
  module Interface
4
- class InitializeParams < WorkDoneProgressParams
4
+ class InitializeParams
5
5
  def initialize(work_done_token: nil, process_id:, client_info: nil, locale: nil, root_path: nil, root_uri:, initialization_options: nil, capabilities:, trace: nil, workspace_folders: nil)
6
6
  @attributes = {}
7
7
 
@@ -19,6 +19,14 @@ module LanguageServer
19
19
  @attributes.freeze
20
20
  end
21
21
 
22
+ #
23
+ # An optional token that a server can use to report work done progress.
24
+ #
25
+ # @return [ProgressToken]
26
+ def work_done_token
27
+ attributes.fetch(:workDoneToken)
28
+ end
29
+
22
30
  #
23
31
  # The process Id of the parent process that started the server. Is null if
24
32
  # the process has not been started by another process. If the parent
@@ -1,7 +1,7 @@
1
1
  module LanguageServer
2
2
  module Protocol
3
3
  module Interface
4
- class LinkedEditingRangeOptions < WorkDoneProgressOptions
4
+ class LinkedEditingRangeOptions
5
5
  def initialize(work_done_progress: nil)
6
6
  @attributes = {}
7
7
 
@@ -10,6 +10,11 @@ module LanguageServer
10
10
  @attributes.freeze
11
11
  end
12
12
 
13
+ # @return [boolean]
14
+ def work_done_progress
15
+ attributes.fetch(:workDoneProgress)
16
+ end
17
+
13
18
  attr_reader :attributes
14
19
 
15
20
  def to_hash
@@ -1,15 +1,41 @@
1
1
  module LanguageServer
2
2
  module Protocol
3
3
  module Interface
4
- class LinkedEditingRangeParams < WorkDoneProgressParams
5
- def initialize(work_done_token: nil)
4
+ class LinkedEditingRangeParams
5
+ def initialize(text_document:, position:, work_done_token: nil)
6
6
  @attributes = {}
7
7
 
8
+ @attributes[:textDocument] = text_document
9
+ @attributes[:position] = position
8
10
  @attributes[:workDoneToken] = work_done_token if work_done_token
9
11
 
10
12
  @attributes.freeze
11
13
  end
12
14
 
15
+ #
16
+ # The text document.
17
+ #
18
+ # @return [TextDocumentIdentifier]
19
+ def text_document
20
+ attributes.fetch(:textDocument)
21
+ end
22
+
23
+ #
24
+ # The position inside the text document.
25
+ #
26
+ # @return [Position]
27
+ def position
28
+ attributes.fetch(:position)
29
+ end
30
+
31
+ #
32
+ # An optional token that a server can use to report work done progress.
33
+ #
34
+ # @return [ProgressToken]
35
+ def work_done_token
36
+ attributes.fetch(:workDoneToken)
37
+ end
38
+
13
39
  attr_reader :attributes
14
40
 
15
41
  def to_hash
@@ -1,15 +1,40 @@
1
1
  module LanguageServer
2
2
  module Protocol
3
3
  module Interface
4
- class LinkedEditingRangeRegistrationOptions < StaticRegistrationOptions
5
- def initialize(id: nil)
4
+ class LinkedEditingRangeRegistrationOptions
5
+ def initialize(document_selector:, work_done_progress: nil, id: nil)
6
6
  @attributes = {}
7
7
 
8
+ @attributes[:documentSelector] = document_selector
9
+ @attributes[:workDoneProgress] = work_done_progress if work_done_progress
8
10
  @attributes[:id] = id if id
9
11
 
10
12
  @attributes.freeze
11
13
  end
12
14
 
15
+ #
16
+ # A document selector to identify the scope of the registration. If set to
17
+ # null the document selector provided on the client side will be used.
18
+ #
19
+ # @return [DocumentSelector]
20
+ def document_selector
21
+ attributes.fetch(:documentSelector)
22
+ end
23
+
24
+ # @return [boolean]
25
+ def work_done_progress
26
+ attributes.fetch(:workDoneProgress)
27
+ end
28
+
29
+ #
30
+ # The id used to register the request. The id can be used to deregister
31
+ # the request again. See also Registration#id.
32
+ #
33
+ # @return [string]
34
+ def id
35
+ attributes.fetch(:id)
36
+ end
37
+
13
38
  attr_reader :attributes
14
39
 
15
40
  def to_hash
@@ -1,7 +1,7 @@
1
1
  module LanguageServer
2
2
  module Protocol
3
3
  module Interface
4
- class MonikerOptions < WorkDoneProgressOptions
4
+ class MonikerOptions
5
5
  def initialize(work_done_progress: nil)
6
6
  @attributes = {}
7
7
 
@@ -10,6 +10,11 @@ module LanguageServer
10
10
  @attributes.freeze
11
11
  end
12
12
 
13
+ # @return [boolean]
14
+ def work_done_progress
15
+ attributes.fetch(:workDoneProgress)
16
+ end
17
+
13
18
  attr_reader :attributes
14
19
 
15
20
  def to_hash
@@ -1,15 +1,51 @@
1
1
  module LanguageServer
2
2
  module Protocol
3
3
  module Interface
4
- class MonikerParams < PartialResultParams
5
- def initialize(partial_result_token: nil)
4
+ class MonikerParams
5
+ def initialize(text_document:, position:, work_done_token: nil, partial_result_token: nil)
6
6
  @attributes = {}
7
7
 
8
+ @attributes[:textDocument] = text_document
9
+ @attributes[:position] = position
10
+ @attributes[:workDoneToken] = work_done_token if work_done_token
8
11
  @attributes[:partialResultToken] = partial_result_token if partial_result_token
9
12
 
10
13
  @attributes.freeze
11
14
  end
12
15
 
16
+ #
17
+ # The text document.
18
+ #
19
+ # @return [TextDocumentIdentifier]
20
+ def text_document
21
+ attributes.fetch(:textDocument)
22
+ end
23
+
24
+ #
25
+ # The position inside the text document.
26
+ #
27
+ # @return [Position]
28
+ def position
29
+ attributes.fetch(:position)
30
+ end
31
+
32
+ #
33
+ # An optional token that a server can use to report work done progress.
34
+ #
35
+ # @return [ProgressToken]
36
+ def work_done_token
37
+ attributes.fetch(:workDoneToken)
38
+ end
39
+
40
+ #
41
+ # An optional token that a server can use to report partial results (e.g.
42
+ # streaming) to the client.
43
+ #
44
+ # @return [ProgressToken]
45
+ def partial_result_token
46
+ attributes.fetch(:partialResultToken)
47
+ end
48
+
13
49
  attr_reader :attributes
14
50
 
15
51
  def to_hash
@@ -1,15 +1,30 @@
1
1
  module LanguageServer
2
2
  module Protocol
3
3
  module Interface
4
- class MonikerRegistrationOptions < MonikerOptions
5
- def initialize(work_done_progress: nil)
4
+ class MonikerRegistrationOptions
5
+ def initialize(document_selector:, work_done_progress: nil)
6
6
  @attributes = {}
7
7
 
8
+ @attributes[:documentSelector] = document_selector
8
9
  @attributes[:workDoneProgress] = work_done_progress if work_done_progress
9
10
 
10
11
  @attributes.freeze
11
12
  end
12
13
 
14
+ #
15
+ # A document selector to identify the scope of the registration. If set to
16
+ # null the document selector provided on the client side will be used.
17
+ #
18
+ # @return [DocumentSelector]
19
+ def document_selector
20
+ attributes.fetch(:documentSelector)
21
+ end
22
+
23
+ # @return [boolean]
24
+ def work_done_progress
25
+ attributes.fetch(:workDoneProgress)
26
+ end
27
+
13
28
  attr_reader :attributes
14
29
 
15
30
  def to_hash
@@ -1,7 +1,7 @@
1
1
  module LanguageServer
2
2
  module Protocol
3
3
  module Interface
4
- class NotificationMessage < Message
4
+ class NotificationMessage
5
5
  def initialize(jsonrpc:, method:, params: nil)
6
6
  @attributes = {}
7
7
 
@@ -12,6 +12,11 @@ module LanguageServer
12
12
  @attributes.freeze
13
13
  end
14
14
 
15
+ # @return [string]
16
+ def jsonrpc
17
+ attributes.fetch(:jsonrpc)
18
+ end
19
+
15
20
  #
16
21
  # The method to be invoked.
17
22
  #
@@ -1,7 +1,7 @@
1
1
  module LanguageServer
2
2
  module Protocol
3
3
  module Interface
4
- class OptionalVersionedTextDocumentIdentifier < TextDocumentIdentifier
4
+ class OptionalVersionedTextDocumentIdentifier
5
5
  def initialize(uri:, version:)
6
6
  @attributes = {}
7
7
 
@@ -11,6 +11,14 @@ module LanguageServer
11
11
  @attributes.freeze
12
12
  end
13
13
 
14
+ #
15
+ # The text document's URI.
16
+ #
17
+ # @return [string]
18
+ def uri
19
+ attributes.fetch(:uri)
20
+ end
21
+
14
22
  #
15
23
  # The version number of this document. If an optional versioned text document
16
24
  # identifier is sent from the server to the client and the file is not
@@ -1,7 +1,7 @@
1
1
  module LanguageServer
2
2
  module Protocol
3
3
  module Interface
4
- class PrepareRenameParams < TextDocumentPositionParams
4
+ class PrepareRenameParams
5
5
  def initialize(text_document:, position:)
6
6
  @attributes = {}
7
7
 
@@ -11,6 +11,22 @@ module LanguageServer
11
11
  @attributes.freeze
12
12
  end
13
13
 
14
+ #
15
+ # The text document.
16
+ #
17
+ # @return [TextDocumentIdentifier]
18
+ def text_document
19
+ attributes.fetch(:textDocument)
20
+ end
21
+
22
+ #
23
+ # The position inside the text document.
24
+ #
25
+ # @return [Position]
26
+ def position
27
+ attributes.fetch(:position)
28
+ end
29
+
14
30
  attr_reader :attributes
15
31
 
16
32
  def to_hash
@@ -1,7 +1,7 @@
1
1
  module LanguageServer
2
2
  module Protocol
3
3
  module Interface
4
- class ReferenceOptions < WorkDoneProgressOptions
4
+ class ReferenceOptions
5
5
  def initialize(work_done_progress: nil)
6
6
  @attributes = {}
7
7
 
@@ -10,6 +10,11 @@ module LanguageServer
10
10
  @attributes.freeze
11
11
  end
12
12
 
13
+ # @return [boolean]
14
+ def work_done_progress
15
+ attributes.fetch(:workDoneProgress)
16
+ end
17
+
13
18
  attr_reader :attributes
14
19
 
15
20
  def to_hash
@@ -1,16 +1,52 @@
1
1
  module LanguageServer
2
2
  module Protocol
3
3
  module Interface
4
- class ReferenceParams < PartialResultParams
5
- def initialize(partial_result_token: nil, context:)
4
+ class ReferenceParams
5
+ def initialize(text_document:, position:, work_done_token: nil, partial_result_token: nil, context:)
6
6
  @attributes = {}
7
7
 
8
+ @attributes[:textDocument] = text_document
9
+ @attributes[:position] = position
10
+ @attributes[:workDoneToken] = work_done_token if work_done_token
8
11
  @attributes[:partialResultToken] = partial_result_token if partial_result_token
9
12
  @attributes[:context] = context
10
13
 
11
14
  @attributes.freeze
12
15
  end
13
16
 
17
+ #
18
+ # The text document.
19
+ #
20
+ # @return [TextDocumentIdentifier]
21
+ def text_document
22
+ attributes.fetch(:textDocument)
23
+ end
24
+
25
+ #
26
+ # The position inside the text document.
27
+ #
28
+ # @return [Position]
29
+ def position
30
+ attributes.fetch(:position)
31
+ end
32
+
33
+ #
34
+ # An optional token that a server can use to report work done progress.
35
+ #
36
+ # @return [ProgressToken]
37
+ def work_done_token
38
+ attributes.fetch(:workDoneToken)
39
+ end
40
+
41
+ #
42
+ # An optional token that a server can use to report partial results (e.g.
43
+ # streaming) to the client.
44
+ #
45
+ # @return [ProgressToken]
46
+ def partial_result_token
47
+ attributes.fetch(:partialResultToken)
48
+ end
49
+
14
50
  # @return [ReferenceContext]
15
51
  def context
16
52
  attributes.fetch(:context)
@@ -1,15 +1,30 @@
1
1
  module LanguageServer
2
2
  module Protocol
3
3
  module Interface
4
- class ReferenceRegistrationOptions < ReferenceOptions
5
- def initialize(work_done_progress: nil)
4
+ class ReferenceRegistrationOptions
5
+ def initialize(document_selector:, work_done_progress: nil)
6
6
  @attributes = {}
7
7
 
8
+ @attributes[:documentSelector] = document_selector
8
9
  @attributes[:workDoneProgress] = work_done_progress if work_done_progress
9
10
 
10
11
  @attributes.freeze
11
12
  end
12
13
 
14
+ #
15
+ # A document selector to identify the scope of the registration. If set to
16
+ # null the document selector provided on the client side will be used.
17
+ #
18
+ # @return [DocumentSelector]
19
+ def document_selector
20
+ attributes.fetch(:documentSelector)
21
+ end
22
+
23
+ # @return [boolean]
24
+ def work_done_progress
25
+ attributes.fetch(:workDoneProgress)
26
+ end
27
+
13
28
  attr_reader :attributes
14
29
 
15
30
  def to_hash