language_server-protocol 3.16.0.3 → 3.17.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/language_server/protocol/constant/code_action_kind.rb +25 -24
- data/lib/language_server/protocol/constant/code_action_trigger_kind.rb +24 -0
- data/lib/language_server/protocol/constant/completion_item_tag.rb +4 -2
- data/lib/language_server/protocol/constant/completion_trigger_kind.rb +2 -3
- data/lib/language_server/protocol/constant/diagnostic_severity.rb +3 -0
- data/lib/language_server/protocol/constant/diagnostic_tag.rb +4 -2
- data/lib/language_server/protocol/constant/error_codes.rb +19 -14
- data/lib/language_server/protocol/constant/failure_handling_kind.rb +9 -10
- data/lib/language_server/protocol/constant/file_change_type.rb +1 -1
- data/lib/language_server/protocol/constant/file_operation_pattern_kind.rb +4 -2
- data/lib/language_server/protocol/constant/folding_range_kind.rb +23 -0
- data/lib/language_server/protocol/constant/inlay_hint_kind.rb +21 -0
- data/lib/language_server/protocol/constant/insert_text_format.rb +2 -0
- data/lib/language_server/protocol/constant/insert_text_mode.rb +2 -0
- data/lib/language_server/protocol/constant/lsp_error_codes.rb +55 -0
- data/lib/language_server/protocol/constant/markup_kind.rb +2 -2
- data/lib/language_server/protocol/constant/message_type.rb +3 -0
- data/lib/language_server/protocol/constant/moniker_kind.rb +26 -0
- data/lib/language_server/protocol/constant/notebook_cell_kind.rb +21 -0
- data/lib/language_server/protocol/constant/position_encoding_kind.rb +32 -0
- data/lib/language_server/protocol/constant/resource_operation_kind.rb +3 -6
- data/lib/language_server/protocol/constant/semantic_token_modifiers.rb +25 -0
- data/lib/language_server/protocol/constant/semantic_token_types.rb +45 -0
- data/lib/language_server/protocol/constant/signature_help_trigger_kind.rb +3 -2
- data/lib/language_server/protocol/constant/symbol_tag.rb +2 -0
- data/lib/language_server/protocol/constant/text_document_save_reason.rb +2 -2
- data/lib/language_server/protocol/constant/text_document_sync_kind.rb +3 -3
- data/lib/language_server/protocol/constant/token_format.rb +1 -1
- data/lib/language_server/protocol/constant/trace_values.rb +20 -0
- data/lib/language_server/protocol/constant/uniqueness_level.rb +33 -0
- data/lib/language_server/protocol/constant.rb +22 -4
- data/lib/language_server/protocol/interface/annotated_text_edit.rb +12 -10
- data/lib/language_server/protocol/interface/apply_workspace_edit_params.rb +4 -1
- data/lib/language_server/protocol/interface/{apply_workspace_edit_response.rb → apply_workspace_edit_result.rb} +11 -7
- data/lib/language_server/protocol/interface/base_symbol_information.rb +68 -0
- data/lib/language_server/protocol/interface/call_hierarchy_client_capabilities.rb +7 -5
- data/lib/language_server/protocol/interface/call_hierarchy_incoming_call.rb +5 -0
- data/lib/language_server/protocol/interface/call_hierarchy_incoming_calls_params.rb +16 -11
- data/lib/language_server/protocol/interface/call_hierarchy_item.rb +14 -10
- data/lib/language_server/protocol/interface/call_hierarchy_options.rb +6 -1
- data/lib/language_server/protocol/interface/call_hierarchy_outgoing_call.rb +8 -2
- data/lib/language_server/protocol/interface/call_hierarchy_outgoing_calls_params.rb +16 -11
- data/lib/language_server/protocol/interface/call_hierarchy_prepare_params.rb +6 -1
- data/lib/language_server/protocol/interface/call_hierarchy_registration_options.rb +10 -5
- data/lib/language_server/protocol/interface/cancel_params.rb +1 -1
- data/lib/language_server/protocol/interface/change_annotation.rb +4 -2
- data/lib/language_server/protocol/interface/client_capabilities.rb +22 -6
- data/lib/language_server/protocol/interface/code_action.rb +28 -26
- data/lib/language_server/protocol/interface/code_action_client_capabilities.rb +25 -9
- data/lib/language_server/protocol/interface/code_action_context.rb +20 -10
- data/lib/language_server/protocol/interface/code_action_options.rb +16 -11
- data/lib/language_server/protocol/interface/code_action_params.rb +21 -21
- data/lib/language_server/protocol/interface/code_action_registration_options.rb +19 -14
- data/lib/language_server/protocol/interface/code_description.rb +3 -1
- data/lib/language_server/protocol/interface/code_lens.rb +8 -9
- data/lib/language_server/protocol/interface/code_lens_client_capabilities.rb +4 -1
- data/lib/language_server/protocol/interface/code_lens_options.rb +11 -8
- data/lib/language_server/protocol/interface/code_lens_params.rb +17 -14
- data/lib/language_server/protocol/interface/code_lens_registration_options.rb +14 -11
- data/lib/language_server/protocol/interface/code_lens_workspace_client_capabilities.rb +4 -1
- data/lib/language_server/protocol/interface/color.rb +4 -4
- data/lib/language_server/protocol/interface/color_information.rb +3 -0
- data/lib/language_server/protocol/interface/color_presentation.rb +8 -9
- data/lib/language_server/protocol/interface/color_presentation_params.rb +24 -21
- data/lib/language_server/protocol/interface/command.rb +7 -1
- data/lib/language_server/protocol/interface/completion_client_capabilities.rb +33 -5
- data/lib/language_server/protocol/interface/completion_context.rb +4 -6
- data/lib/language_server/protocol/interface/completion_item.rb +92 -49
- data/lib/language_server/protocol/interface/completion_item_label_details.rb +49 -0
- data/lib/language_server/protocol/interface/completion_list.rb +28 -5
- data/lib/language_server/protocol/interface/completion_options.rb +36 -25
- data/lib/language_server/protocol/interface/completion_params.rb +18 -16
- data/lib/language_server/protocol/interface/completion_registration_options.rb +42 -28
- data/lib/language_server/protocol/interface/configuration_item.rb +2 -2
- data/lib/language_server/protocol/interface/configuration_params.rb +3 -0
- data/lib/language_server/protocol/interface/create_file.rb +7 -5
- data/lib/language_server/protocol/interface/create_file_options.rb +2 -2
- data/lib/language_server/protocol/interface/create_files_params.rb +4 -2
- data/lib/language_server/protocol/interface/declaration_client_capabilities.rb +8 -5
- data/lib/language_server/protocol/interface/declaration_options.rb +1 -1
- data/lib/language_server/protocol/interface/declaration_params.rb +4 -4
- data/lib/language_server/protocol/interface/declaration_registration_options.rb +5 -5
- data/lib/language_server/protocol/interface/definition_client_capabilities.rb +7 -2
- data/lib/language_server/protocol/interface/definition_options.rb +4 -1
- data/lib/language_server/protocol/interface/definition_params.rb +7 -4
- data/lib/language_server/protocol/interface/definition_registration_options.rb +7 -4
- data/lib/language_server/protocol/interface/delete_file.rb +6 -4
- data/lib/language_server/protocol/interface/delete_file_options.rb +2 -2
- data/lib/language_server/protocol/interface/delete_files_params.rb +4 -2
- data/lib/language_server/protocol/interface/diagnostic.rb +25 -14
- data/lib/language_server/protocol/interface/diagnostic_client_capabilities.rb +49 -0
- data/lib/language_server/protocol/interface/diagnostic_options.rb +66 -0
- data/lib/language_server/protocol/interface/diagnostic_registration_options.rb +86 -0
- data/lib/language_server/protocol/interface/diagnostic_related_information.rb +3 -3
- data/lib/language_server/protocol/interface/diagnostic_server_cancellation_data.rb +35 -0
- data/lib/language_server/protocol/interface/diagnostic_workspace_client_capabilities.rb +44 -0
- data/lib/language_server/protocol/interface/did_change_configuration_client_capabilities.rb +1 -1
- data/lib/language_server/protocol/interface/did_change_configuration_params.rb +4 -1
- data/lib/language_server/protocol/interface/did_change_configuration_registration_options.rb +30 -0
- data/lib/language_server/protocol/interface/did_change_notebook_document_params.rb +62 -0
- data/lib/language_server/protocol/interface/did_change_text_document_params.rb +12 -11
- data/lib/language_server/protocol/interface/did_change_watched_files_client_capabilities.rb +17 -5
- data/lib/language_server/protocol/interface/did_change_watched_files_params.rb +3 -0
- data/lib/language_server/protocol/interface/did_change_watched_files_registration_options.rb +1 -1
- data/lib/language_server/protocol/interface/did_change_workspace_folders_params.rb +3 -0
- data/lib/language_server/protocol/interface/did_close_notebook_document_params.rb +48 -0
- data/lib/language_server/protocol/interface/did_close_text_document_params.rb +3 -0
- data/lib/language_server/protocol/interface/did_open_notebook_document_params.rb +48 -0
- data/lib/language_server/protocol/interface/did_open_text_document_params.rb +3 -0
- data/lib/language_server/protocol/interface/did_save_notebook_document_params.rb +38 -0
- data/lib/language_server/protocol/interface/did_save_text_document_params.rb +4 -1
- data/lib/language_server/protocol/interface/document_color_client_capabilities.rb +4 -2
- data/lib/language_server/protocol/interface/document_color_options.rb +1 -1
- data/lib/language_server/protocol/interface/document_color_params.rb +17 -14
- data/lib/language_server/protocol/interface/document_color_registration_options.rb +11 -11
- data/lib/language_server/protocol/interface/document_diagnostic_params.rb +75 -0
- data/lib/language_server/protocol/interface/document_diagnostic_report.rb +77 -0
- data/lib/language_server/protocol/interface/document_diagnostic_report_partial_result.rb +35 -0
- data/lib/language_server/protocol/interface/document_filter.rb +25 -19
- data/lib/language_server/protocol/interface/document_formatting_client_capabilities.rb +4 -1
- data/lib/language_server/protocol/interface/document_formatting_options.rb +4 -1
- data/lib/language_server/protocol/interface/document_formatting_params.rb +13 -10
- data/lib/language_server/protocol/interface/document_formatting_registration_options.rb +7 -4
- data/lib/language_server/protocol/interface/document_highlight.rb +2 -2
- data/lib/language_server/protocol/interface/document_highlight_client_capabilities.rb +4 -1
- data/lib/language_server/protocol/interface/document_highlight_options.rb +4 -1
- data/lib/language_server/protocol/interface/document_highlight_params.rb +7 -4
- data/lib/language_server/protocol/interface/document_highlight_registration_options.rb +7 -4
- data/lib/language_server/protocol/interface/document_link.rb +10 -9
- data/lib/language_server/protocol/interface/document_link_client_capabilities.rb +7 -2
- data/lib/language_server/protocol/interface/document_link_options.rb +11 -8
- data/lib/language_server/protocol/interface/document_link_params.rb +17 -14
- data/lib/language_server/protocol/interface/document_link_registration_options.rb +14 -11
- data/lib/language_server/protocol/interface/document_on_type_formatting_client_capabilities.rb +4 -1
- data/lib/language_server/protocol/interface/document_on_type_formatting_options.rb +5 -2
- data/lib/language_server/protocol/interface/document_on_type_formatting_params.rb +12 -4
- data/lib/language_server/protocol/interface/document_on_type_formatting_registration_options.rb +8 -5
- data/lib/language_server/protocol/interface/document_range_formatting_client_capabilities.rb +5 -2
- data/lib/language_server/protocol/interface/document_range_formatting_options.rb +4 -1
- data/lib/language_server/protocol/interface/document_range_formatting_params.rb +13 -10
- data/lib/language_server/protocol/interface/document_range_formatting_registration_options.rb +7 -4
- data/lib/language_server/protocol/interface/document_symbol.rb +18 -16
- data/lib/language_server/protocol/interface/document_symbol_client_capabilities.rb +12 -5
- data/lib/language_server/protocol/interface/document_symbol_options.rb +13 -8
- data/lib/language_server/protocol/interface/document_symbol_params.rb +17 -14
- data/lib/language_server/protocol/interface/document_symbol_registration_options.rb +16 -11
- data/lib/language_server/protocol/interface/execute_command_client_capabilities.rb +4 -1
- data/lib/language_server/protocol/interface/execute_command_options.rb +10 -7
- data/lib/language_server/protocol/interface/execute_command_params.rb +14 -11
- data/lib/language_server/protocol/interface/execute_command_registration_options.rb +8 -8
- data/lib/language_server/protocol/interface/execution_summary.rb +45 -0
- data/lib/language_server/protocol/interface/file_create.rb +2 -0
- data/lib/language_server/protocol/interface/file_delete.rb +2 -0
- data/lib/language_server/protocol/interface/file_event.rb +3 -3
- data/lib/language_server/protocol/interface/file_operation_client_capabilities.rb +95 -0
- data/lib/language_server/protocol/interface/file_operation_filter.rb +5 -3
- data/lib/language_server/protocol/interface/file_operation_options.rb +83 -0
- data/lib/language_server/protocol/interface/file_operation_pattern.rb +8 -10
- data/lib/language_server/protocol/interface/file_operation_pattern_options.rb +3 -1
- data/lib/language_server/protocol/interface/file_operation_registration_options.rb +2 -0
- data/lib/language_server/protocol/interface/file_rename.rb +2 -0
- data/lib/language_server/protocol/interface/file_system_watcher.rb +4 -14
- data/lib/language_server/protocol/interface/folding_range.rb +30 -23
- data/lib/language_server/protocol/interface/folding_range_client_capabilities.rb +26 -4
- data/lib/language_server/protocol/interface/folding_range_options.rb +1 -1
- data/lib/language_server/protocol/interface/folding_range_params.rb +17 -14
- data/lib/language_server/protocol/interface/folding_range_registration_options.rb +5 -5
- data/lib/language_server/protocol/interface/formatting_options.rb +10 -4
- data/lib/language_server/protocol/interface/full_document_diagnostic_report.rb +58 -0
- data/lib/language_server/protocol/interface/general_client_capabilities.rb +91 -0
- data/lib/language_server/protocol/interface/glob_pattern.rb +48 -0
- data/lib/language_server/protocol/interface/hover.rb +3 -3
- data/lib/language_server/protocol/interface/hover_client_capabilities.rb +4 -5
- data/lib/language_server/protocol/interface/hover_options.rb +4 -1
- data/lib/language_server/protocol/interface/hover_params.rb +4 -1
- data/lib/language_server/protocol/interface/hover_registration_options.rb +7 -4
- data/lib/language_server/protocol/interface/implementation_client_capabilities.rb +10 -5
- data/lib/language_server/protocol/interface/implementation_options.rb +1 -1
- data/lib/language_server/protocol/interface/implementation_params.rb +4 -4
- data/lib/language_server/protocol/interface/implementation_registration_options.rb +5 -5
- data/lib/language_server/protocol/interface/initialize_error.rb +2 -1
- data/lib/language_server/protocol/interface/initialize_params.rb +41 -29
- data/lib/language_server/protocol/interface/initialize_result.rb +6 -1
- data/lib/language_server/protocol/interface/inlay_hint.rb +118 -0
- data/lib/language_server/protocol/interface/inlay_hint_client_capabilities.rb +48 -0
- data/lib/language_server/protocol/interface/inlay_hint_label_part.rb +81 -0
- data/lib/language_server/protocol/interface/inlay_hint_options.rb +45 -0
- data/lib/language_server/protocol/interface/inlay_hint_params.rb +56 -0
- data/lib/language_server/protocol/interface/inlay_hint_registration_options.rb +65 -0
- data/lib/language_server/protocol/interface/inlay_hint_workspace_client_capabilities.rb +44 -0
- data/lib/language_server/protocol/interface/inline_value.rb +78 -0
- data/lib/language_server/protocol/interface/inline_value_client_capabilities.rb +38 -0
- data/lib/language_server/protocol/interface/inline_value_context.rb +46 -0
- data/lib/language_server/protocol/interface/inline_value_evaluatable_expression.rb +50 -0
- data/lib/language_server/protocol/interface/inline_value_options.rb +35 -0
- data/lib/language_server/protocol/interface/inline_value_params.rb +66 -0
- data/lib/language_server/protocol/interface/inline_value_registration_options.rb +55 -0
- data/lib/language_server/protocol/interface/inline_value_text.rb +47 -0
- data/lib/language_server/protocol/interface/inline_value_variable_lookup.rb +59 -0
- data/lib/language_server/protocol/interface/inline_value_workspace_client_capabilities.rb +44 -0
- data/lib/language_server/protocol/interface/insert_replace_edit.rb +2 -0
- data/lib/language_server/protocol/interface/linked_editing_range_client_capabilities.rb +8 -4
- data/lib/language_server/protocol/interface/linked_editing_range_options.rb +1 -1
- data/lib/language_server/protocol/interface/linked_editing_range_params.rb +1 -1
- data/lib/language_server/protocol/interface/linked_editing_range_registration_options.rb +5 -5
- data/lib/language_server/protocol/interface/linked_editing_ranges.rb +7 -2
- data/lib/language_server/protocol/interface/location.rb +5 -1
- data/lib/language_server/protocol/interface/location_link.rb +13 -11
- data/lib/language_server/protocol/interface/log_message_params.rb +4 -1
- data/lib/language_server/protocol/interface/log_trace_params.rb +1 -8
- data/lib/language_server/protocol/interface/{message.rb → lsp_object.rb} +6 -8
- data/lib/language_server/protocol/interface/markdown_client_capabilities.rb +16 -2
- data/lib/language_server/protocol/interface/markup_content.rb +16 -18
- data/lib/language_server/protocol/interface/moniker.rb +3 -1
- data/lib/language_server/protocol/interface/moniker_client_capabilities.rb +9 -5
- data/lib/language_server/protocol/interface/moniker_options.rb +1 -1
- data/lib/language_server/protocol/interface/moniker_params.rb +4 -4
- data/lib/language_server/protocol/interface/moniker_registration_options.rb +4 -4
- data/lib/language_server/protocol/interface/notebook_cell.rb +73 -0
- data/lib/language_server/protocol/interface/notebook_cell_array_change.rb +57 -0
- data/lib/language_server/protocol/interface/notebook_cell_text_document_filter.rb +54 -0
- data/lib/language_server/protocol/interface/notebook_document.rb +78 -0
- data/lib/language_server/protocol/interface/notebook_document_change_event.rb +49 -0
- data/lib/language_server/protocol/interface/notebook_document_client_capabilities.rb +40 -0
- data/lib/language_server/protocol/interface/notebook_document_filter.rb +58 -0
- data/lib/language_server/protocol/interface/notebook_document_identifier.rb +38 -0
- data/lib/language_server/protocol/interface/notebook_document_sync_client_capabilities.rb +50 -0
- data/lib/language_server/protocol/interface/notebook_document_sync_options.rb +58 -0
- data/lib/language_server/protocol/interface/notebook_document_sync_registration_options.rb +58 -0
- data/lib/language_server/protocol/interface/optional_versioned_text_document_identifier.rb +17 -18
- data/lib/language_server/protocol/interface/parameter_information.rb +7 -9
- data/lib/language_server/protocol/interface/partial_result_params.rb +3 -3
- data/lib/language_server/protocol/interface/position.rb +40 -7
- data/lib/language_server/protocol/interface/prepare_rename_params.rb +10 -1
- data/lib/language_server/protocol/interface/prepare_rename_result.rb +60 -0
- data/lib/language_server/protocol/interface/previous_result_id.rb +48 -0
- data/lib/language_server/protocol/interface/progress_params.rb +1 -1
- data/lib/language_server/protocol/interface/publish_diagnostics_client_capabilities.rb +16 -5
- data/lib/language_server/protocol/interface/publish_diagnostics_params.rb +8 -4
- data/lib/language_server/protocol/interface/range.rb +13 -0
- data/lib/language_server/protocol/interface/reference_client_capabilities.rb +4 -1
- data/lib/language_server/protocol/interface/reference_context.rb +4 -0
- data/lib/language_server/protocol/interface/reference_options.rb +4 -1
- data/lib/language_server/protocol/interface/reference_params.rb +14 -11
- data/lib/language_server/protocol/interface/reference_registration_options.rb +7 -4
- data/lib/language_server/protocol/interface/registration.rb +2 -2
- data/lib/language_server/protocol/interface/regular_expressions_client_capabilities.rb +3 -1
- data/lib/language_server/protocol/interface/related_full_document_diagnostic_report.rb +73 -0
- data/lib/language_server/protocol/interface/related_unchanged_document_diagnostic_report.rb +66 -0
- data/lib/language_server/protocol/interface/relative_pattern.rb +50 -0
- data/lib/language_server/protocol/interface/rename_client_capabilities.rb +12 -7
- data/lib/language_server/protocol/interface/rename_file.rb +7 -5
- data/lib/language_server/protocol/interface/rename_file_options.rb +2 -2
- data/lib/language_server/protocol/interface/rename_files_params.rb +6 -4
- data/lib/language_server/protocol/interface/rename_options.rb +13 -8
- data/lib/language_server/protocol/interface/rename_params.rb +15 -12
- data/lib/language_server/protocol/interface/rename_registration_options.rb +16 -11
- data/lib/language_server/protocol/interface/resource_operation.rb +47 -0
- data/lib/language_server/protocol/interface/save_options.rb +4 -1
- data/lib/language_server/protocol/interface/selection_range.rb +6 -3
- data/lib/language_server/protocol/interface/selection_range_client_capabilities.rb +4 -5
- data/lib/language_server/protocol/interface/selection_range_options.rb +1 -1
- data/lib/language_server/protocol/interface/selection_range_params.rb +23 -20
- data/lib/language_server/protocol/interface/selection_range_registration_options.rb +5 -5
- data/lib/language_server/protocol/interface/semantic_tokens.rb +5 -2
- data/lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb +45 -11
- data/lib/language_server/protocol/interface/semantic_tokens_delta.rb +5 -3
- data/lib/language_server/protocol/interface/semantic_tokens_delta_params.rb +24 -21
- data/lib/language_server/protocol/interface/semantic_tokens_delta_partial_result.rb +3 -0
- data/lib/language_server/protocol/interface/semantic_tokens_edit.rb +6 -3
- data/lib/language_server/protocol/interface/semantic_tokens_legend.rb +3 -0
- data/lib/language_server/protocol/interface/semantic_tokens_options.rb +12 -9
- data/lib/language_server/protocol/interface/semantic_tokens_params.rb +17 -14
- data/lib/language_server/protocol/interface/semantic_tokens_partial_result.rb +4 -1
- data/lib/language_server/protocol/interface/semantic_tokens_range_params.rb +23 -20
- data/lib/language_server/protocol/interface/semantic_tokens_registration_options.rb +16 -13
- data/lib/language_server/protocol/interface/semantic_tokens_workspace_client_capabilities.rb +5 -2
- data/lib/language_server/protocol/interface/server_capabilities.rb +139 -56
- data/lib/language_server/protocol/interface/set_trace_params.rb +1 -4
- data/lib/language_server/protocol/interface/show_document_client_capabilities.rb +4 -2
- data/lib/language_server/protocol/interface/show_document_params.rb +6 -4
- data/lib/language_server/protocol/interface/show_document_result.rb +3 -1
- data/lib/language_server/protocol/interface/show_message_params.rb +4 -1
- data/lib/language_server/protocol/interface/show_message_request_client_capabilities.rb +1 -1
- data/lib/language_server/protocol/interface/show_message_request_params.rb +2 -2
- data/lib/language_server/protocol/interface/signature_help.rb +3 -4
- data/lib/language_server/protocol/interface/signature_help_client_capabilities.rb +8 -3
- data/lib/language_server/protocol/interface/signature_help_context.rb +10 -11
- data/lib/language_server/protocol/interface/signature_help_options.rb +17 -14
- data/lib/language_server/protocol/interface/signature_help_params.rb +17 -13
- data/lib/language_server/protocol/interface/signature_help_registration_options.rb +20 -17
- data/lib/language_server/protocol/interface/signature_information.rb +5 -3
- data/lib/language_server/protocol/interface/static_registration_options.rb +3 -2
- data/lib/language_server/protocol/interface/symbol_information.rb +34 -30
- data/lib/language_server/protocol/interface/t.rb +24 -0
- data/lib/language_server/protocol/interface/text_document_change_registration_options.rb +12 -13
- data/lib/language_server/protocol/interface/text_document_client_capabilities.rb +108 -43
- data/lib/language_server/protocol/interface/text_document_content_change_event.rb +8 -10
- data/lib/language_server/protocol/interface/text_document_edit.rb +10 -1
- data/lib/language_server/protocol/interface/text_document_filter.rb +69 -0
- data/lib/language_server/protocol/interface/text_document_identifier.rb +5 -2
- data/lib/language_server/protocol/interface/text_document_item.rb +7 -3
- data/lib/language_server/protocol/interface/text_document_position_params.rb +4 -0
- data/lib/language_server/protocol/interface/text_document_registration_options.rb +3 -3
- data/lib/language_server/protocol/interface/text_document_save_registration_options.rb +7 -4
- data/lib/language_server/protocol/interface/text_document_sync_client_capabilities.rb +4 -4
- data/lib/language_server/protocol/interface/text_document_sync_options.rb +15 -17
- data/lib/language_server/protocol/interface/text_edit.rb +3 -0
- data/lib/language_server/protocol/interface/type_definition_client_capabilities.rb +10 -5
- data/lib/language_server/protocol/interface/type_definition_options.rb +1 -1
- data/lib/language_server/protocol/interface/type_definition_params.rb +4 -4
- data/lib/language_server/protocol/interface/type_definition_registration_options.rb +5 -5
- data/lib/language_server/protocol/interface/type_hierarchy_client_capabilities.rb +38 -0
- data/lib/language_server/protocol/interface/type_hierarchy_item.rb +105 -0
- data/lib/language_server/protocol/interface/type_hierarchy_options.rb +35 -0
- data/lib/language_server/protocol/interface/type_hierarchy_prepare_params.rb +56 -0
- data/lib/language_server/protocol/interface/type_hierarchy_registration_options.rb +55 -0
- data/lib/language_server/protocol/interface/type_hierarchy_subtypes_params.rb +54 -0
- data/lib/language_server/protocol/interface/type_hierarchy_supertypes_params.rb +54 -0
- data/lib/language_server/protocol/interface/unchanged_document_diagnostic_report.rb +52 -0
- data/lib/language_server/protocol/interface/unregistration.rb +2 -2
- data/lib/language_server/protocol/interface/versioned_notebook_document_identifier.rb +47 -0
- data/lib/language_server/protocol/interface/versioned_text_document_identifier.rb +13 -13
- data/lib/language_server/protocol/interface/will_save_text_document_params.rb +1 -1
- data/lib/language_server/protocol/interface/window_client_capabilities.rb +63 -0
- data/lib/language_server/protocol/interface/work_done_progress_begin.rb +6 -6
- data/lib/language_server/protocol/interface/work_done_progress_end.rb +1 -1
- data/lib/language_server/protocol/interface/work_done_progress_options.rb +1 -1
- data/lib/language_server/protocol/interface/work_done_progress_params.rb +1 -1
- data/lib/language_server/protocol/interface/work_done_progress_report.rb +6 -7
- data/lib/language_server/protocol/interface/workspace_client_capabilities.rb +176 -0
- data/lib/language_server/protocol/interface/workspace_diagnostic_params.rb +67 -0
- data/lib/language_server/protocol/interface/workspace_diagnostic_report.rb +35 -0
- data/lib/language_server/protocol/interface/workspace_diagnostic_report_partial_result.rb +35 -0
- data/lib/language_server/protocol/interface/workspace_document_diagnostic_report.rb +77 -0
- data/lib/language_server/protocol/interface/workspace_edit.rb +28 -17
- data/lib/language_server/protocol/interface/workspace_edit_client_capabilities.rb +15 -6
- data/lib/language_server/protocol/interface/workspace_folder.rb +4 -1
- data/lib/language_server/protocol/interface/workspace_folders_initialize_params.rb +39 -0
- data/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb +3 -3
- data/lib/language_server/protocol/interface/workspace_full_document_diagnostic_report.rb +77 -0
- data/lib/language_server/protocol/interface/workspace_symbol.rb +95 -0
- data/lib/language_server/protocol/interface/workspace_symbol_client_capabilities.rb +23 -6
- data/lib/language_server/protocol/interface/workspace_symbol_options.rb +17 -2
- data/lib/language_server/protocol/interface/workspace_symbol_params.rb +16 -16
- data/lib/language_server/protocol/interface/workspace_symbol_registration_options.rb +17 -2
- data/lib/language_server/protocol/interface/workspace_unchanged_document_diagnostic_report.rb +70 -0
- data/lib/language_server/protocol/interface.rb +156 -14
- data/lib/language_server/protocol/version.rb +1 -1
- metadata +92 -10
- data/lib/language_server/protocol/constant/initialize_error.rb +0 -16
- data/lib/language_server/protocol/interface/notification_message.rb +0 -48
- data/lib/language_server/protocol/interface/request_message.rb +0 -57
- data/lib/language_server/protocol/interface/response_error.rb +0 -52
- data/lib/language_server/protocol/interface/response_message.rb +0 -58
@@ -0,0 +1,75 @@
|
|
1
|
+
module LanguageServer
|
2
|
+
module Protocol
|
3
|
+
module Interface
|
4
|
+
#
|
5
|
+
# Parameters of the document diagnostic request.
|
6
|
+
#
|
7
|
+
# @since 3.17.0
|
8
|
+
#
|
9
|
+
class DocumentDiagnosticParams
|
10
|
+
def initialize(text_document:, identifier: nil, previous_result_id: nil, work_done_token: nil, partial_result_token: nil)
|
11
|
+
@attributes = {}
|
12
|
+
|
13
|
+
@attributes[:textDocument] = text_document
|
14
|
+
@attributes[:identifier] = identifier if identifier
|
15
|
+
@attributes[:previousResultId] = previous_result_id if previous_result_id
|
16
|
+
@attributes[:workDoneToken] = work_done_token if work_done_token
|
17
|
+
@attributes[:partialResultToken] = partial_result_token if partial_result_token
|
18
|
+
|
19
|
+
@attributes.freeze
|
20
|
+
end
|
21
|
+
|
22
|
+
#
|
23
|
+
# The text document.
|
24
|
+
#
|
25
|
+
# @return [TextDocumentIdentifier]
|
26
|
+
def text_document
|
27
|
+
attributes.fetch(:textDocument)
|
28
|
+
end
|
29
|
+
|
30
|
+
#
|
31
|
+
# The additional identifier provided during registration.
|
32
|
+
#
|
33
|
+
# @return [string | nil]
|
34
|
+
def identifier
|
35
|
+
attributes.fetch(:identifier)
|
36
|
+
end
|
37
|
+
|
38
|
+
#
|
39
|
+
# The result id of a previous response if provided.
|
40
|
+
#
|
41
|
+
# @return [string | nil]
|
42
|
+
def previous_result_id
|
43
|
+
attributes.fetch(:previousResultId)
|
44
|
+
end
|
45
|
+
|
46
|
+
#
|
47
|
+
# An optional token that a server can use to report work done progress.
|
48
|
+
#
|
49
|
+
# @return [ProgressToken | nil]
|
50
|
+
def work_done_token
|
51
|
+
attributes.fetch(:workDoneToken)
|
52
|
+
end
|
53
|
+
|
54
|
+
#
|
55
|
+
# An optional token that a server can use to report partial results (e.g. streaming) to
|
56
|
+
# the client.
|
57
|
+
#
|
58
|
+
# @return [ProgressToken | nil]
|
59
|
+
def partial_result_token
|
60
|
+
attributes.fetch(:partialResultToken)
|
61
|
+
end
|
62
|
+
|
63
|
+
attr_reader :attributes
|
64
|
+
|
65
|
+
def to_hash
|
66
|
+
attributes
|
67
|
+
end
|
68
|
+
|
69
|
+
def to_json(*args)
|
70
|
+
to_hash.to_json(*args)
|
71
|
+
end
|
72
|
+
end
|
73
|
+
end
|
74
|
+
end
|
75
|
+
end
|
@@ -0,0 +1,77 @@
|
|
1
|
+
module LanguageServer
|
2
|
+
module Protocol
|
3
|
+
module Interface
|
4
|
+
#
|
5
|
+
# The result of a document diagnostic pull request. A report can
|
6
|
+
# either be a full report containing all diagnostics for the
|
7
|
+
# requested document or an unchanged report indicating that nothing
|
8
|
+
# has changed in terms of diagnostics in comparison to the last
|
9
|
+
# pull request.
|
10
|
+
#
|
11
|
+
# @since 3.17.0
|
12
|
+
#
|
13
|
+
class DocumentDiagnosticReport
|
14
|
+
def initialize(related_documents: nil, kind:, result_id: nil, items:)
|
15
|
+
@attributes = {}
|
16
|
+
|
17
|
+
@attributes[:relatedDocuments] = related_documents if related_documents
|
18
|
+
@attributes[:kind] = kind
|
19
|
+
@attributes[:resultId] = result_id if result_id
|
20
|
+
@attributes[:items] = items
|
21
|
+
|
22
|
+
@attributes.freeze
|
23
|
+
end
|
24
|
+
|
25
|
+
#
|
26
|
+
# Diagnostics of related documents. This information is useful
|
27
|
+
# in programming languages where code in a file A can generate
|
28
|
+
# diagnostics in a file B which A depends on. An example of
|
29
|
+
# such a language is C/C++ where marco definitions in a file
|
30
|
+
# a.cpp and result in errors in a header file b.hpp.
|
31
|
+
#
|
32
|
+
# @since 3.17.0
|
33
|
+
#
|
34
|
+
# @return [DocumentUri => FullDocumentDiagnosticReport | UnchangedDocumentDiagnosticReport | nil]
|
35
|
+
def related_documents
|
36
|
+
attributes.fetch(:relatedDocuments)
|
37
|
+
end
|
38
|
+
|
39
|
+
#
|
40
|
+
# A full document diagnostic report.
|
41
|
+
#
|
42
|
+
# @return ["full"]
|
43
|
+
def kind
|
44
|
+
attributes.fetch(:kind)
|
45
|
+
end
|
46
|
+
|
47
|
+
#
|
48
|
+
# An optional result id. If provided it will
|
49
|
+
# be sent on the next diagnostic request for the
|
50
|
+
# same document.
|
51
|
+
#
|
52
|
+
# @return [string | nil]
|
53
|
+
def result_id
|
54
|
+
attributes.fetch(:resultId)
|
55
|
+
end
|
56
|
+
|
57
|
+
#
|
58
|
+
# The actual items.
|
59
|
+
#
|
60
|
+
# @return [Diagnostic[]]
|
61
|
+
def items
|
62
|
+
attributes.fetch(:items)
|
63
|
+
end
|
64
|
+
|
65
|
+
attr_reader :attributes
|
66
|
+
|
67
|
+
def to_hash
|
68
|
+
attributes
|
69
|
+
end
|
70
|
+
|
71
|
+
def to_json(*args)
|
72
|
+
to_hash.to_json(*args)
|
73
|
+
end
|
74
|
+
end
|
75
|
+
end
|
76
|
+
end
|
77
|
+
end
|
@@ -0,0 +1,35 @@
|
|
1
|
+
module LanguageServer
|
2
|
+
module Protocol
|
3
|
+
module Interface
|
4
|
+
#
|
5
|
+
# A partial result for a document diagnostic report.
|
6
|
+
#
|
7
|
+
# @since 3.17.0
|
8
|
+
#
|
9
|
+
class DocumentDiagnosticReportPartialResult
|
10
|
+
def initialize(related_documents:)
|
11
|
+
@attributes = {}
|
12
|
+
|
13
|
+
@attributes[:relatedDocuments] = related_documents
|
14
|
+
|
15
|
+
@attributes.freeze
|
16
|
+
end
|
17
|
+
|
18
|
+
# @return [DocumentUri => FullDocumentDiagnosticReport | UnchangedDocumentDiagnosticReport]
|
19
|
+
def related_documents
|
20
|
+
attributes.fetch(:relatedDocuments)
|
21
|
+
end
|
22
|
+
|
23
|
+
attr_reader :attributes
|
24
|
+
|
25
|
+
def to_hash
|
26
|
+
attributes
|
27
|
+
end
|
28
|
+
|
29
|
+
def to_json(*args)
|
30
|
+
to_hash.to_json(*args)
|
31
|
+
end
|
32
|
+
end
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
@@ -1,19 +1,26 @@
|
|
1
1
|
module LanguageServer
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
|
+
#
|
5
|
+
# A document filter describes a top level text document or
|
6
|
+
# a notebook cell document.
|
7
|
+
#
|
8
|
+
# @since 3.17.0 - proposed support for NotebookCellTextDocumentFilter.
|
9
|
+
#
|
4
10
|
class DocumentFilter
|
5
|
-
def initialize(language: nil,
|
11
|
+
def initialize(language:, scheme: nil, pattern: nil, notebook:)
|
6
12
|
@attributes = {}
|
7
13
|
|
8
|
-
@attributes[:language] = language
|
14
|
+
@attributes[:language] = language
|
9
15
|
@attributes[:scheme] = scheme if scheme
|
10
16
|
@attributes[:pattern] = pattern if pattern
|
17
|
+
@attributes[:notebook] = notebook
|
11
18
|
|
12
19
|
@attributes.freeze
|
13
20
|
end
|
14
21
|
|
15
22
|
#
|
16
|
-
# A language id, like `typescript`.
|
23
|
+
# A language id, like `typescript`. */
|
17
24
|
#
|
18
25
|
# @return [string]
|
19
26
|
def language
|
@@ -21,33 +28,32 @@ module LanguageServer
|
|
21
28
|
end
|
22
29
|
|
23
30
|
#
|
24
|
-
# A Uri [scheme](#Uri.scheme), like `file` or `untitled`.
|
31
|
+
# A Uri [scheme](#Uri.scheme), like `file` or `untitled`. */
|
25
32
|
#
|
26
|
-
# @return [string]
|
33
|
+
# @return [string | nil]
|
27
34
|
def scheme
|
28
35
|
attributes.fetch(:scheme)
|
29
36
|
end
|
30
37
|
|
31
38
|
#
|
32
|
-
# A glob pattern, like `*.{ts,js}`.
|
33
|
-
#
|
34
|
-
# Glob patterns can have the following syntax:
|
35
|
-
# - `*` to match one or more characters in a path segment
|
36
|
-
# - `?` to match on one character in a path segment
|
37
|
-
# - `**` to match any number of path segments, including none
|
38
|
-
# - `{}` to group sub patterns into an OR expression. (e.g. `**/*.{ts,js}`
|
39
|
-
# matches all TypeScript and JavaScript files)
|
40
|
-
# - `[]` to declare a range of characters to match in a path segment
|
41
|
-
# (e.g., `example.[0-9]` to match on `example.0`, `example.1`, …)
|
42
|
-
# - `[!...]` to negate a range of characters to match in a path segment
|
43
|
-
# (e.g., `example.[!0-9]` to match on `example.a`, `example.b`, but
|
44
|
-
# not `example.0`)
|
39
|
+
# A glob pattern, like `*.{ts,js}`. */
|
45
40
|
#
|
46
|
-
# @return [string]
|
41
|
+
# @return [string | nil]
|
47
42
|
def pattern
|
48
43
|
attributes.fetch(:pattern)
|
49
44
|
end
|
50
45
|
|
46
|
+
#
|
47
|
+
# A filter that matches against the notebook
|
48
|
+
# containing the notebook cell. If a string
|
49
|
+
# value is provided it matches against the
|
50
|
+
# notebook type. '*' matches every notebook.
|
51
|
+
#
|
52
|
+
# @return [string | NotebookDocumentFilter]
|
53
|
+
def notebook
|
54
|
+
attributes.fetch(:notebook)
|
55
|
+
end
|
56
|
+
|
51
57
|
attr_reader :attributes
|
52
58
|
|
53
59
|
def to_hash
|
@@ -1,6 +1,9 @@
|
|
1
1
|
module LanguageServer
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
|
+
#
|
5
|
+
# Client capabilities of a [DocumentFormattingRequest](#DocumentFormattingRequest).
|
6
|
+
#
|
4
7
|
class DocumentFormattingClientCapabilities
|
5
8
|
def initialize(dynamic_registration: nil)
|
6
9
|
@attributes = {}
|
@@ -13,7 +16,7 @@ module LanguageServer
|
|
13
16
|
#
|
14
17
|
# Whether formatting supports dynamic registration.
|
15
18
|
#
|
16
|
-
# @return [boolean]
|
19
|
+
# @return [boolean | nil]
|
17
20
|
def dynamic_registration
|
18
21
|
attributes.fetch(:dynamicRegistration)
|
19
22
|
end
|
@@ -1,6 +1,9 @@
|
|
1
1
|
module LanguageServer
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
|
+
#
|
5
|
+
# Provider options for a [DocumentFormattingRequest](#DocumentFormattingRequest).
|
6
|
+
#
|
4
7
|
class DocumentFormattingOptions
|
5
8
|
def initialize(work_done_progress: nil)
|
6
9
|
@attributes = {}
|
@@ -10,7 +13,7 @@ module LanguageServer
|
|
10
13
|
@attributes.freeze
|
11
14
|
end
|
12
15
|
|
13
|
-
# @return [boolean]
|
16
|
+
# @return [boolean | nil]
|
14
17
|
def work_done_progress
|
15
18
|
attributes.fetch(:workDoneProgress)
|
16
19
|
end
|
@@ -1,25 +1,20 @@
|
|
1
1
|
module LanguageServer
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
|
+
#
|
5
|
+
# The parameters of a [DocumentFormattingRequest](#DocumentFormattingRequest).
|
6
|
+
#
|
4
7
|
class DocumentFormattingParams
|
5
|
-
def initialize(
|
8
|
+
def initialize(text_document:, options:, work_done_token: nil)
|
6
9
|
@attributes = {}
|
7
10
|
|
8
|
-
@attributes[:workDoneToken] = work_done_token if work_done_token
|
9
11
|
@attributes[:textDocument] = text_document
|
10
12
|
@attributes[:options] = options
|
13
|
+
@attributes[:workDoneToken] = work_done_token if work_done_token
|
11
14
|
|
12
15
|
@attributes.freeze
|
13
16
|
end
|
14
17
|
|
15
|
-
#
|
16
|
-
# An optional token that a server can use to report work done progress.
|
17
|
-
#
|
18
|
-
# @return [ProgressToken]
|
19
|
-
def work_done_token
|
20
|
-
attributes.fetch(:workDoneToken)
|
21
|
-
end
|
22
|
-
|
23
18
|
#
|
24
19
|
# The document to format.
|
25
20
|
#
|
@@ -36,6 +31,14 @@ module LanguageServer
|
|
36
31
|
attributes.fetch(:options)
|
37
32
|
end
|
38
33
|
|
34
|
+
#
|
35
|
+
# An optional token that a server can use to report work done progress.
|
36
|
+
#
|
37
|
+
# @return [ProgressToken | nil]
|
38
|
+
def work_done_token
|
39
|
+
attributes.fetch(:workDoneToken)
|
40
|
+
end
|
41
|
+
|
39
42
|
attr_reader :attributes
|
40
43
|
|
41
44
|
def to_hash
|
@@ -1,6 +1,9 @@
|
|
1
1
|
module LanguageServer
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
|
+
#
|
5
|
+
# Registration options for a [DocumentFormattingRequest](#DocumentFormattingRequest).
|
6
|
+
#
|
4
7
|
class DocumentFormattingRegistrationOptions
|
5
8
|
def initialize(document_selector:, work_done_progress: nil)
|
6
9
|
@attributes = {}
|
@@ -12,15 +15,15 @@ module LanguageServer
|
|
12
15
|
end
|
13
16
|
|
14
17
|
#
|
15
|
-
# A document selector to identify the scope of the registration. If set to
|
16
|
-
#
|
18
|
+
# A document selector to identify the scope of the registration. If set to null
|
19
|
+
# the document selector provided on the client side will be used.
|
17
20
|
#
|
18
|
-
# @return [DocumentSelector]
|
21
|
+
# @return [DocumentSelector | null]
|
19
22
|
def document_selector
|
20
23
|
attributes.fetch(:documentSelector)
|
21
24
|
end
|
22
25
|
|
23
|
-
# @return [boolean]
|
26
|
+
# @return [boolean | nil]
|
24
27
|
def work_done_progress
|
25
28
|
attributes.fetch(:workDoneProgress)
|
26
29
|
end
|
@@ -25,9 +25,9 @@ module LanguageServer
|
|
25
25
|
end
|
26
26
|
|
27
27
|
#
|
28
|
-
# The highlight kind, default is DocumentHighlightKind.Text.
|
28
|
+
# The highlight kind, default is [text](#DocumentHighlightKind.Text).
|
29
29
|
#
|
30
|
-
# @return [DocumentHighlightKind]
|
30
|
+
# @return [DocumentHighlightKind | nil]
|
31
31
|
def kind
|
32
32
|
attributes.fetch(:kind)
|
33
33
|
end
|
@@ -1,6 +1,9 @@
|
|
1
1
|
module LanguageServer
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
|
+
#
|
5
|
+
# Client Capabilities for a [DocumentHighlightRequest](#DocumentHighlightRequest).
|
6
|
+
#
|
4
7
|
class DocumentHighlightClientCapabilities
|
5
8
|
def initialize(dynamic_registration: nil)
|
6
9
|
@attributes = {}
|
@@ -13,7 +16,7 @@ module LanguageServer
|
|
13
16
|
#
|
14
17
|
# Whether document highlight supports dynamic registration.
|
15
18
|
#
|
16
|
-
# @return [boolean]
|
19
|
+
# @return [boolean | nil]
|
17
20
|
def dynamic_registration
|
18
21
|
attributes.fetch(:dynamicRegistration)
|
19
22
|
end
|
@@ -1,6 +1,9 @@
|
|
1
1
|
module LanguageServer
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
|
+
#
|
5
|
+
# Provider options for a [DocumentHighlightRequest](#DocumentHighlightRequest).
|
6
|
+
#
|
4
7
|
class DocumentHighlightOptions
|
5
8
|
def initialize(work_done_progress: nil)
|
6
9
|
@attributes = {}
|
@@ -10,7 +13,7 @@ module LanguageServer
|
|
10
13
|
@attributes.freeze
|
11
14
|
end
|
12
15
|
|
13
|
-
# @return [boolean]
|
16
|
+
# @return [boolean | nil]
|
14
17
|
def work_done_progress
|
15
18
|
attributes.fetch(:workDoneProgress)
|
16
19
|
end
|
@@ -1,6 +1,9 @@
|
|
1
1
|
module LanguageServer
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
|
+
#
|
5
|
+
# Parameters for a [DocumentHighlightRequest](#DocumentHighlightRequest).
|
6
|
+
#
|
4
7
|
class DocumentHighlightParams
|
5
8
|
def initialize(text_document:, position:, work_done_token: nil, partial_result_token: nil)
|
6
9
|
@attributes = {}
|
@@ -32,16 +35,16 @@ module LanguageServer
|
|
32
35
|
#
|
33
36
|
# An optional token that a server can use to report work done progress.
|
34
37
|
#
|
35
|
-
# @return [ProgressToken]
|
38
|
+
# @return [ProgressToken | nil]
|
36
39
|
def work_done_token
|
37
40
|
attributes.fetch(:workDoneToken)
|
38
41
|
end
|
39
42
|
|
40
43
|
#
|
41
|
-
# An optional token that a server can use to report partial results (e.g.
|
42
|
-
#
|
44
|
+
# An optional token that a server can use to report partial results (e.g. streaming) to
|
45
|
+
# the client.
|
43
46
|
#
|
44
|
-
# @return [ProgressToken]
|
47
|
+
# @return [ProgressToken | nil]
|
45
48
|
def partial_result_token
|
46
49
|
attributes.fetch(:partialResultToken)
|
47
50
|
end
|
@@ -1,6 +1,9 @@
|
|
1
1
|
module LanguageServer
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
|
+
#
|
5
|
+
# Registration options for a [DocumentHighlightRequest](#DocumentHighlightRequest).
|
6
|
+
#
|
4
7
|
class DocumentHighlightRegistrationOptions
|
5
8
|
def initialize(document_selector:, work_done_progress: nil)
|
6
9
|
@attributes = {}
|
@@ -12,15 +15,15 @@ module LanguageServer
|
|
12
15
|
end
|
13
16
|
|
14
17
|
#
|
15
|
-
# A document selector to identify the scope of the registration. If set to
|
16
|
-
#
|
18
|
+
# A document selector to identify the scope of the registration. If set to null
|
19
|
+
# the document selector provided on the client side will be used.
|
17
20
|
#
|
18
|
-
# @return [DocumentSelector]
|
21
|
+
# @return [DocumentSelector | null]
|
19
22
|
def document_selector
|
20
23
|
attributes.fetch(:documentSelector)
|
21
24
|
end
|
22
25
|
|
23
|
-
# @return [boolean]
|
26
|
+
# @return [boolean | nil]
|
24
27
|
def work_done_progress
|
25
28
|
attributes.fetch(:workDoneProgress)
|
26
29
|
end
|
@@ -2,8 +2,8 @@ module LanguageServer
|
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
4
|
#
|
5
|
-
# A document link is a range in a text document that links to an internal or
|
6
|
-
#
|
5
|
+
# A document link is a range in a text document that links to an internal or external resource, like another
|
6
|
+
# text document or a web site.
|
7
7
|
#
|
8
8
|
class DocumentLink
|
9
9
|
def initialize(range:, target: nil, tooltip: nil, data: nil)
|
@@ -28,7 +28,7 @@ module LanguageServer
|
|
28
28
|
#
|
29
29
|
# The uri this link points to. If missing a resolve request is sent later.
|
30
30
|
#
|
31
|
-
# @return [string]
|
31
|
+
# @return [string | nil]
|
32
32
|
def target
|
33
33
|
attributes.fetch(:target)
|
34
34
|
end
|
@@ -36,12 +36,13 @@ module LanguageServer
|
|
36
36
|
#
|
37
37
|
# The tooltip text when you hover over this link.
|
38
38
|
#
|
39
|
-
# If a tooltip is provided, is will be displayed in a string that includes
|
40
|
-
#
|
41
|
-
#
|
42
|
-
# localization.
|
39
|
+
# If a tooltip is provided, is will be displayed in a string that includes instructions on how to
|
40
|
+
# trigger the link, such as `{0} (ctrl + click)`. The specific instructions vary depending on OS,
|
41
|
+
# user settings, and localization.
|
43
42
|
#
|
44
|
-
# @
|
43
|
+
# @since 3.15.0
|
44
|
+
#
|
45
|
+
# @return [string | nil]
|
45
46
|
def tooltip
|
46
47
|
attributes.fetch(:tooltip)
|
47
48
|
end
|
@@ -50,7 +51,7 @@ module LanguageServer
|
|
50
51
|
# A data entry field that is preserved on a document link between a
|
51
52
|
# DocumentLinkRequest and a DocumentLinkResolveRequest.
|
52
53
|
#
|
53
|
-
# @return [
|
54
|
+
# @return [LSPAny | nil]
|
54
55
|
def data
|
55
56
|
attributes.fetch(:data)
|
56
57
|
end
|
@@ -1,6 +1,9 @@
|
|
1
1
|
module LanguageServer
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
|
+
#
|
5
|
+
# The client capabilities of a [DocumentLinkRequest](#DocumentLinkRequest).
|
6
|
+
#
|
4
7
|
class DocumentLinkClientCapabilities
|
5
8
|
def initialize(dynamic_registration: nil, tooltip_support: nil)
|
6
9
|
@attributes = {}
|
@@ -14,7 +17,7 @@ module LanguageServer
|
|
14
17
|
#
|
15
18
|
# Whether document link supports dynamic registration.
|
16
19
|
#
|
17
|
-
# @return [boolean]
|
20
|
+
# @return [boolean | nil]
|
18
21
|
def dynamic_registration
|
19
22
|
attributes.fetch(:dynamicRegistration)
|
20
23
|
end
|
@@ -22,7 +25,9 @@ module LanguageServer
|
|
22
25
|
#
|
23
26
|
# Whether the client supports the `tooltip` property on `DocumentLink`.
|
24
27
|
#
|
25
|
-
# @
|
28
|
+
# @since 3.15.0
|
29
|
+
#
|
30
|
+
# @return [boolean | nil]
|
26
31
|
def tooltip_support
|
27
32
|
attributes.fetch(:tooltipSupport)
|
28
33
|
end
|
@@ -1,29 +1,32 @@
|
|
1
1
|
module LanguageServer
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
|
+
#
|
5
|
+
# Provider options for a [DocumentLinkRequest](#DocumentLinkRequest).
|
6
|
+
#
|
4
7
|
class DocumentLinkOptions
|
5
|
-
def initialize(
|
8
|
+
def initialize(resolve_provider: nil, work_done_progress: nil)
|
6
9
|
@attributes = {}
|
7
10
|
|
8
|
-
@attributes[:workDoneProgress] = work_done_progress if work_done_progress
|
9
11
|
@attributes[:resolveProvider] = resolve_provider if resolve_provider
|
12
|
+
@attributes[:workDoneProgress] = work_done_progress if work_done_progress
|
10
13
|
|
11
14
|
@attributes.freeze
|
12
15
|
end
|
13
16
|
|
14
|
-
# @return [boolean]
|
15
|
-
def work_done_progress
|
16
|
-
attributes.fetch(:workDoneProgress)
|
17
|
-
end
|
18
|
-
|
19
17
|
#
|
20
18
|
# Document links have a resolve provider as well.
|
21
19
|
#
|
22
|
-
# @return [boolean]
|
20
|
+
# @return [boolean | nil]
|
23
21
|
def resolve_provider
|
24
22
|
attributes.fetch(:resolveProvider)
|
25
23
|
end
|
26
24
|
|
25
|
+
# @return [boolean | nil]
|
26
|
+
def work_done_progress
|
27
|
+
attributes.fetch(:workDoneProgress)
|
28
|
+
end
|
29
|
+
|
27
30
|
attr_reader :attributes
|
28
31
|
|
29
32
|
def to_hash
|
@@ -1,42 +1,45 @@
|
|
1
1
|
module LanguageServer
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
|
+
#
|
5
|
+
# The parameters of a [DocumentLinkRequest](#DocumentLinkRequest).
|
6
|
+
#
|
4
7
|
class DocumentLinkParams
|
5
|
-
def initialize(work_done_token: nil, partial_result_token: nil
|
8
|
+
def initialize(text_document:, work_done_token: nil, partial_result_token: nil)
|
6
9
|
@attributes = {}
|
7
10
|
|
11
|
+
@attributes[:textDocument] = text_document
|
8
12
|
@attributes[:workDoneToken] = work_done_token if work_done_token
|
9
13
|
@attributes[:partialResultToken] = partial_result_token if partial_result_token
|
10
|
-
@attributes[:textDocument] = text_document
|
11
14
|
|
12
15
|
@attributes.freeze
|
13
16
|
end
|
14
17
|
|
18
|
+
#
|
19
|
+
# The document to provide document links for.
|
20
|
+
#
|
21
|
+
# @return [TextDocumentIdentifier]
|
22
|
+
def text_document
|
23
|
+
attributes.fetch(:textDocument)
|
24
|
+
end
|
25
|
+
|
15
26
|
#
|
16
27
|
# An optional token that a server can use to report work done progress.
|
17
28
|
#
|
18
|
-
# @return [ProgressToken]
|
29
|
+
# @return [ProgressToken | nil]
|
19
30
|
def work_done_token
|
20
31
|
attributes.fetch(:workDoneToken)
|
21
32
|
end
|
22
33
|
|
23
34
|
#
|
24
|
-
# An optional token that a server can use to report partial results (e.g.
|
25
|
-
#
|
35
|
+
# An optional token that a server can use to report partial results (e.g. streaming) to
|
36
|
+
# the client.
|
26
37
|
#
|
27
|
-
# @return [ProgressToken]
|
38
|
+
# @return [ProgressToken | nil]
|
28
39
|
def partial_result_token
|
29
40
|
attributes.fetch(:partialResultToken)
|
30
41
|
end
|
31
42
|
|
32
|
-
#
|
33
|
-
# The document to provide document links for.
|
34
|
-
#
|
35
|
-
# @return [TextDocumentIdentifier]
|
36
|
-
def text_document
|
37
|
-
attributes.fetch(:textDocument)
|
38
|
-
end
|
39
|
-
|
40
43
|
attr_reader :attributes
|
41
44
|
|
42
45
|
def to_hash
|