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
@@ -1,20 +1,18 @@
|
|
1
1
|
module LanguageServer
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
|
-
|
5
|
-
|
4
|
+
#
|
5
|
+
# LSP object definition.
|
6
|
+
# @since 3.17.0
|
7
|
+
#
|
8
|
+
class LSPObject
|
9
|
+
def initialize()
|
6
10
|
@attributes = {}
|
7
11
|
|
8
|
-
@attributes[:jsonrpc] = jsonrpc
|
9
12
|
|
10
13
|
@attributes.freeze
|
11
14
|
end
|
12
15
|
|
13
|
-
# @return [string]
|
14
|
-
def jsonrpc
|
15
|
-
attributes.fetch(:jsonrpc)
|
16
|
-
end
|
17
|
-
|
18
16
|
attr_reader :attributes
|
19
17
|
|
20
18
|
def to_hash
|
@@ -4,12 +4,15 @@ module LanguageServer
|
|
4
4
|
#
|
5
5
|
# Client capabilities specific to the used markdown parser.
|
6
6
|
#
|
7
|
+
# @since 3.16.0
|
8
|
+
#
|
7
9
|
class MarkdownClientCapabilities
|
8
|
-
def initialize(parser:, version: nil)
|
10
|
+
def initialize(parser:, version: nil, allowed_tags: nil)
|
9
11
|
@attributes = {}
|
10
12
|
|
11
13
|
@attributes[:parser] = parser
|
12
14
|
@attributes[:version] = version if version
|
15
|
+
@attributes[:allowedTags] = allowed_tags if allowed_tags
|
13
16
|
|
14
17
|
@attributes.freeze
|
15
18
|
end
|
@@ -25,11 +28,22 @@ module LanguageServer
|
|
25
28
|
#
|
26
29
|
# The version of the parser.
|
27
30
|
#
|
28
|
-
# @return [string]
|
31
|
+
# @return [string | nil]
|
29
32
|
def version
|
30
33
|
attributes.fetch(:version)
|
31
34
|
end
|
32
35
|
|
36
|
+
#
|
37
|
+
# A list of HTML tags that the client allows / supports in
|
38
|
+
# Markdown.
|
39
|
+
#
|
40
|
+
# @since 3.17.0
|
41
|
+
#
|
42
|
+
# @return [string[] | nil]
|
43
|
+
def allowed_tags
|
44
|
+
attributes.fetch(:allowedTags)
|
45
|
+
end
|
46
|
+
|
33
47
|
attr_reader :attributes
|
34
48
|
|
35
49
|
def to_hash
|
@@ -2,30 +2,28 @@ module LanguageServer
|
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
4
|
#
|
5
|
-
# A `MarkupContent` literal represents a string value which content is
|
6
|
-
#
|
7
|
-
# `plaintext` and `markdown` as markup kinds.
|
5
|
+
# A `MarkupContent` literal represents a string value which content is interpreted base on its
|
6
|
+
# kind flag. Currently the protocol supports `plaintext` and `markdown` as markup kinds.
|
8
7
|
#
|
9
|
-
# If the kind is `markdown` then the value can contain fenced code blocks like
|
10
|
-
#
|
8
|
+
# If the kind is `markdown` then the value can contain fenced code blocks like in GitHub issues.
|
9
|
+
# See https://help.github.com/articles/creating-and-highlighting-code-blocks/#syntax-highlighting
|
11
10
|
#
|
12
|
-
# Here is an example how such a string can be constructed using
|
13
|
-
#
|
14
|
-
# ```typescript
|
11
|
+
# Here is an example how such a string can be constructed using JavaScript / TypeScript:
|
12
|
+
# ```ts
|
15
13
|
# let markdown: MarkdownContent = {
|
16
|
-
#
|
17
|
-
#
|
18
|
-
#
|
19
|
-
#
|
20
|
-
#
|
21
|
-
#
|
22
|
-
#
|
23
|
-
#
|
14
|
+
# kind: MarkupKind.Markdown,
|
15
|
+
# value: [
|
16
|
+
# '# Header',
|
17
|
+
# 'Some text',
|
18
|
+
# '```typescript',
|
19
|
+
# 'someCode();',
|
20
|
+
# '```'
|
21
|
+
# ].join('\n')
|
24
22
|
# };
|
25
23
|
# ```
|
26
24
|
#
|
27
|
-
# *Please Note* that clients might sanitize the return markdown. A client could
|
28
|
-
#
|
25
|
+
# *Please Note* that clients might sanitize the return markdown. A client could decide to
|
26
|
+
# remove HTML from the markdown to avoid script execution.
|
29
27
|
#
|
30
28
|
class MarkupContent
|
31
29
|
def initialize(kind:, value:)
|
@@ -4,6 +4,8 @@ module LanguageServer
|
|
4
4
|
#
|
5
5
|
# Moniker definition to match LSIF 0.5 moniker definition.
|
6
6
|
#
|
7
|
+
# @since 3.16.0
|
8
|
+
#
|
7
9
|
class Moniker
|
8
10
|
def initialize(scheme:, identifier:, unique:, kind: nil)
|
9
11
|
@attributes = {}
|
@@ -44,7 +46,7 @@ module LanguageServer
|
|
44
46
|
#
|
45
47
|
# The moniker kind if known.
|
46
48
|
#
|
47
|
-
# @return [MonikerKind]
|
49
|
+
# @return [MonikerKind | nil]
|
48
50
|
def kind
|
49
51
|
attributes.fetch(:kind)
|
50
52
|
end
|
@@ -1,6 +1,11 @@
|
|
1
1
|
module LanguageServer
|
2
2
|
module Protocol
|
3
3
|
module Interface
|
4
|
+
#
|
5
|
+
# Client capabilities specific to the moniker request.
|
6
|
+
#
|
7
|
+
# @since 3.16.0
|
8
|
+
#
|
4
9
|
class MonikerClientCapabilities
|
5
10
|
def initialize(dynamic_registration: nil)
|
6
11
|
@attributes = {}
|
@@ -11,12 +16,11 @@ module LanguageServer
|
|
11
16
|
end
|
12
17
|
|
13
18
|
#
|
14
|
-
# Whether
|
15
|
-
#
|
16
|
-
#
|
17
|
-
# capability as well.
|
19
|
+
# Whether moniker supports dynamic registration. If this is set to `true`
|
20
|
+
# the client supports the new `MonikerRegistrationOptions` return value
|
21
|
+
# for the corresponding server capability as well.
|
18
22
|
#
|
19
|
-
# @return [boolean]
|
23
|
+
# @return [boolean | nil]
|
20
24
|
def dynamic_registration
|
21
25
|
attributes.fetch(:dynamicRegistration)
|
22
26
|
end
|
@@ -32,16 +32,16 @@ module LanguageServer
|
|
32
32
|
#
|
33
33
|
# An optional token that a server can use to report work done progress.
|
34
34
|
#
|
35
|
-
# @return [ProgressToken]
|
35
|
+
# @return [ProgressToken | nil]
|
36
36
|
def work_done_token
|
37
37
|
attributes.fetch(:workDoneToken)
|
38
38
|
end
|
39
39
|
|
40
40
|
#
|
41
|
-
# An optional token that a server can use to report partial results (e.g.
|
42
|
-
#
|
41
|
+
# An optional token that a server can use to report partial results (e.g. streaming) to
|
42
|
+
# the client.
|
43
43
|
#
|
44
|
-
# @return [ProgressToken]
|
44
|
+
# @return [ProgressToken | nil]
|
45
45
|
def partial_result_token
|
46
46
|
attributes.fetch(:partialResultToken)
|
47
47
|
end
|
@@ -12,15 +12,15 @@ module LanguageServer
|
|
12
12
|
end
|
13
13
|
|
14
14
|
#
|
15
|
-
# A document selector to identify the scope of the registration. If set to
|
16
|
-
#
|
15
|
+
# A document selector to identify the scope of the registration. If set to null
|
16
|
+
# the document selector provided on the client side will be used.
|
17
17
|
#
|
18
|
-
# @return [DocumentSelector]
|
18
|
+
# @return [DocumentSelector | null]
|
19
19
|
def document_selector
|
20
20
|
attributes.fetch(:documentSelector)
|
21
21
|
end
|
22
22
|
|
23
|
-
# @return [boolean]
|
23
|
+
# @return [boolean | nil]
|
24
24
|
def work_done_progress
|
25
25
|
attributes.fetch(:workDoneProgress)
|
26
26
|
end
|
@@ -0,0 +1,73 @@
|
|
1
|
+
module LanguageServer
|
2
|
+
module Protocol
|
3
|
+
module Interface
|
4
|
+
#
|
5
|
+
# A notebook cell.
|
6
|
+
#
|
7
|
+
# A cell's document URI must be unique across ALL notebook
|
8
|
+
# cells and can therefore be used to uniquely identify a
|
9
|
+
# notebook cell or the cell's text document.
|
10
|
+
#
|
11
|
+
# @since 3.17.0
|
12
|
+
#
|
13
|
+
class NotebookCell
|
14
|
+
def initialize(kind:, document:, metadata: nil, execution_summary: nil)
|
15
|
+
@attributes = {}
|
16
|
+
|
17
|
+
@attributes[:kind] = kind
|
18
|
+
@attributes[:document] = document
|
19
|
+
@attributes[:metadata] = metadata if metadata
|
20
|
+
@attributes[:executionSummary] = execution_summary if execution_summary
|
21
|
+
|
22
|
+
@attributes.freeze
|
23
|
+
end
|
24
|
+
|
25
|
+
#
|
26
|
+
# The cell's kind
|
27
|
+
#
|
28
|
+
# @return [NotebookCellKind]
|
29
|
+
def kind
|
30
|
+
attributes.fetch(:kind)
|
31
|
+
end
|
32
|
+
|
33
|
+
#
|
34
|
+
# The URI of the cell's text document
|
35
|
+
# content.
|
36
|
+
#
|
37
|
+
# @return [DocumentUri]
|
38
|
+
def document
|
39
|
+
attributes.fetch(:document)
|
40
|
+
end
|
41
|
+
|
42
|
+
#
|
43
|
+
# Additional metadata stored with the cell.
|
44
|
+
#
|
45
|
+
# Note: should always be an object literal (e.g. LSPObject)
|
46
|
+
#
|
47
|
+
# @return [LSPObject | nil]
|
48
|
+
def metadata
|
49
|
+
attributes.fetch(:metadata)
|
50
|
+
end
|
51
|
+
|
52
|
+
#
|
53
|
+
# Additional execution summary information
|
54
|
+
# if supported by the client.
|
55
|
+
#
|
56
|
+
# @return [ExecutionSummary | nil]
|
57
|
+
def execution_summary
|
58
|
+
attributes.fetch(:executionSummary)
|
59
|
+
end
|
60
|
+
|
61
|
+
attr_reader :attributes
|
62
|
+
|
63
|
+
def to_hash
|
64
|
+
attributes
|
65
|
+
end
|
66
|
+
|
67
|
+
def to_json(*args)
|
68
|
+
to_hash.to_json(*args)
|
69
|
+
end
|
70
|
+
end
|
71
|
+
end
|
72
|
+
end
|
73
|
+
end
|
@@ -0,0 +1,57 @@
|
|
1
|
+
module LanguageServer
|
2
|
+
module Protocol
|
3
|
+
module Interface
|
4
|
+
#
|
5
|
+
# A change describing how to move a `NotebookCell`
|
6
|
+
# array from state S to S'.
|
7
|
+
#
|
8
|
+
# @since 3.17.0
|
9
|
+
#
|
10
|
+
class NotebookCellArrayChange
|
11
|
+
def initialize(start:, delete_count:, cells: nil)
|
12
|
+
@attributes = {}
|
13
|
+
|
14
|
+
@attributes[:start] = start
|
15
|
+
@attributes[:deleteCount] = delete_count
|
16
|
+
@attributes[:cells] = cells if cells
|
17
|
+
|
18
|
+
@attributes.freeze
|
19
|
+
end
|
20
|
+
|
21
|
+
#
|
22
|
+
# The start oftest of the cell that changed.
|
23
|
+
#
|
24
|
+
# @return [uinteger]
|
25
|
+
def start
|
26
|
+
attributes.fetch(:start)
|
27
|
+
end
|
28
|
+
|
29
|
+
#
|
30
|
+
# The deleted cells
|
31
|
+
#
|
32
|
+
# @return [uinteger]
|
33
|
+
def delete_count
|
34
|
+
attributes.fetch(:deleteCount)
|
35
|
+
end
|
36
|
+
|
37
|
+
#
|
38
|
+
# The new cells, if any
|
39
|
+
#
|
40
|
+
# @return [NotebookCell[] | nil]
|
41
|
+
def cells
|
42
|
+
attributes.fetch(:cells)
|
43
|
+
end
|
44
|
+
|
45
|
+
attr_reader :attributes
|
46
|
+
|
47
|
+
def to_hash
|
48
|
+
attributes
|
49
|
+
end
|
50
|
+
|
51
|
+
def to_json(*args)
|
52
|
+
to_hash.to_json(*args)
|
53
|
+
end
|
54
|
+
end
|
55
|
+
end
|
56
|
+
end
|
57
|
+
end
|
@@ -0,0 +1,54 @@
|
|
1
|
+
module LanguageServer
|
2
|
+
module Protocol
|
3
|
+
module Interface
|
4
|
+
#
|
5
|
+
# A notebook cell text document filter denotes a cell text
|
6
|
+
# document by different properties.
|
7
|
+
#
|
8
|
+
# @since 3.17.0
|
9
|
+
#
|
10
|
+
class NotebookCellTextDocumentFilter
|
11
|
+
def initialize(notebook:, language: nil)
|
12
|
+
@attributes = {}
|
13
|
+
|
14
|
+
@attributes[:notebook] = notebook
|
15
|
+
@attributes[:language] = language if language
|
16
|
+
|
17
|
+
@attributes.freeze
|
18
|
+
end
|
19
|
+
|
20
|
+
#
|
21
|
+
# A filter that matches against the notebook
|
22
|
+
# containing the notebook cell. If a string
|
23
|
+
# value is provided it matches against the
|
24
|
+
# notebook type. '*' matches every notebook.
|
25
|
+
#
|
26
|
+
# @return [string | NotebookDocumentFilter]
|
27
|
+
def notebook
|
28
|
+
attributes.fetch(:notebook)
|
29
|
+
end
|
30
|
+
|
31
|
+
#
|
32
|
+
# A language id like `python`.
|
33
|
+
#
|
34
|
+
# Will be matched against the language id of the
|
35
|
+
# notebook cell document. '*' matches every language.
|
36
|
+
#
|
37
|
+
# @return [string | nil]
|
38
|
+
def language
|
39
|
+
attributes.fetch(:language)
|
40
|
+
end
|
41
|
+
|
42
|
+
attr_reader :attributes
|
43
|
+
|
44
|
+
def to_hash
|
45
|
+
attributes
|
46
|
+
end
|
47
|
+
|
48
|
+
def to_json(*args)
|
49
|
+
to_hash.to_json(*args)
|
50
|
+
end
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
54
|
+
end
|
@@ -0,0 +1,78 @@
|
|
1
|
+
module LanguageServer
|
2
|
+
module Protocol
|
3
|
+
module Interface
|
4
|
+
#
|
5
|
+
# A notebook document.
|
6
|
+
#
|
7
|
+
# @since 3.17.0
|
8
|
+
#
|
9
|
+
class NotebookDocument
|
10
|
+
def initialize(uri:, notebook_type:, version:, metadata: nil, cells:)
|
11
|
+
@attributes = {}
|
12
|
+
|
13
|
+
@attributes[:uri] = uri
|
14
|
+
@attributes[:notebookType] = notebook_type
|
15
|
+
@attributes[:version] = version
|
16
|
+
@attributes[:metadata] = metadata if metadata
|
17
|
+
@attributes[:cells] = cells
|
18
|
+
|
19
|
+
@attributes.freeze
|
20
|
+
end
|
21
|
+
|
22
|
+
#
|
23
|
+
# The notebook document's uri.
|
24
|
+
#
|
25
|
+
# @return [URI]
|
26
|
+
def uri
|
27
|
+
attributes.fetch(:uri)
|
28
|
+
end
|
29
|
+
|
30
|
+
#
|
31
|
+
# The type of the notebook.
|
32
|
+
#
|
33
|
+
# @return [string]
|
34
|
+
def notebook_type
|
35
|
+
attributes.fetch(:notebookType)
|
36
|
+
end
|
37
|
+
|
38
|
+
#
|
39
|
+
# The version number of this document (it will increase after each
|
40
|
+
# change, including undo/redo).
|
41
|
+
#
|
42
|
+
# @return [integer]
|
43
|
+
def version
|
44
|
+
attributes.fetch(:version)
|
45
|
+
end
|
46
|
+
|
47
|
+
#
|
48
|
+
# Additional metadata stored with the notebook
|
49
|
+
# document.
|
50
|
+
#
|
51
|
+
# Note: should always be an object literal (e.g. LSPObject)
|
52
|
+
#
|
53
|
+
# @return [LSPObject | nil]
|
54
|
+
def metadata
|
55
|
+
attributes.fetch(:metadata)
|
56
|
+
end
|
57
|
+
|
58
|
+
#
|
59
|
+
# The cells of a notebook.
|
60
|
+
#
|
61
|
+
# @return [NotebookCell[]]
|
62
|
+
def cells
|
63
|
+
attributes.fetch(:cells)
|
64
|
+
end
|
65
|
+
|
66
|
+
attr_reader :attributes
|
67
|
+
|
68
|
+
def to_hash
|
69
|
+
attributes
|
70
|
+
end
|
71
|
+
|
72
|
+
def to_json(*args)
|
73
|
+
to_hash.to_json(*args)
|
74
|
+
end
|
75
|
+
end
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
@@ -0,0 +1,49 @@
|
|
1
|
+
module LanguageServer
|
2
|
+
module Protocol
|
3
|
+
module Interface
|
4
|
+
#
|
5
|
+
# A change event for a notebook document.
|
6
|
+
#
|
7
|
+
# @since 3.17.0
|
8
|
+
#
|
9
|
+
class NotebookDocumentChangeEvent
|
10
|
+
def initialize(metadata: nil, cells: nil)
|
11
|
+
@attributes = {}
|
12
|
+
|
13
|
+
@attributes[:metadata] = metadata if metadata
|
14
|
+
@attributes[:cells] = cells if cells
|
15
|
+
|
16
|
+
@attributes.freeze
|
17
|
+
end
|
18
|
+
|
19
|
+
#
|
20
|
+
# The changed meta data if any.
|
21
|
+
#
|
22
|
+
# Note: should always be an object literal (e.g. LSPObject)
|
23
|
+
#
|
24
|
+
# @return [LSPObject | nil]
|
25
|
+
def metadata
|
26
|
+
attributes.fetch(:metadata)
|
27
|
+
end
|
28
|
+
|
29
|
+
#
|
30
|
+
# Changes to cells
|
31
|
+
#
|
32
|
+
# @return [{ structure:{ array:NotebookCellArrayChange, didOpen:TextDocumentItem[], didClose:TextDocumentIdentifier[] }, data:NotebookCell[], textContent:{ document:VersionedTextDocumentIdentifier, changes:TextDocumentContentChangeEvent[] }[] } | nil]
|
33
|
+
def cells
|
34
|
+
attributes.fetch(:cells)
|
35
|
+
end
|
36
|
+
|
37
|
+
attr_reader :attributes
|
38
|
+
|
39
|
+
def to_hash
|
40
|
+
attributes
|
41
|
+
end
|
42
|
+
|
43
|
+
def to_json(*args)
|
44
|
+
to_hash.to_json(*args)
|
45
|
+
end
|
46
|
+
end
|
47
|
+
end
|
48
|
+
end
|
49
|
+
end
|
@@ -0,0 +1,40 @@
|
|
1
|
+
module LanguageServer
|
2
|
+
module Protocol
|
3
|
+
module Interface
|
4
|
+
#
|
5
|
+
# Capabilities specific to the notebook document support.
|
6
|
+
#
|
7
|
+
# @since 3.17.0
|
8
|
+
#
|
9
|
+
class NotebookDocumentClientCapabilities
|
10
|
+
def initialize(synchronization:)
|
11
|
+
@attributes = {}
|
12
|
+
|
13
|
+
@attributes[:synchronization] = synchronization
|
14
|
+
|
15
|
+
@attributes.freeze
|
16
|
+
end
|
17
|
+
|
18
|
+
#
|
19
|
+
# Capabilities specific to notebook document synchronization
|
20
|
+
#
|
21
|
+
# @since 3.17.0
|
22
|
+
#
|
23
|
+
# @return [NotebookDocumentSyncClientCapabilities]
|
24
|
+
def synchronization
|
25
|
+
attributes.fetch(:synchronization)
|
26
|
+
end
|
27
|
+
|
28
|
+
attr_reader :attributes
|
29
|
+
|
30
|
+
def to_hash
|
31
|
+
attributes
|
32
|
+
end
|
33
|
+
|
34
|
+
def to_json(*args)
|
35
|
+
to_hash.to_json(*args)
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
@@ -0,0 +1,58 @@
|
|
1
|
+
module LanguageServer
|
2
|
+
module Protocol
|
3
|
+
module Interface
|
4
|
+
#
|
5
|
+
# A notebook document filter denotes a notebook document by
|
6
|
+
# different properties. The properties will be match
|
7
|
+
# against the notebook's URI (same as with documents)
|
8
|
+
#
|
9
|
+
# @since 3.17.0
|
10
|
+
#
|
11
|
+
class NotebookDocumentFilter
|
12
|
+
def initialize(notebook_type:, scheme: nil, pattern: nil)
|
13
|
+
@attributes = {}
|
14
|
+
|
15
|
+
@attributes[:notebookType] = notebook_type
|
16
|
+
@attributes[:scheme] = scheme if scheme
|
17
|
+
@attributes[:pattern] = pattern if pattern
|
18
|
+
|
19
|
+
@attributes.freeze
|
20
|
+
end
|
21
|
+
|
22
|
+
#
|
23
|
+
# The type of the enclosing notebook. */
|
24
|
+
#
|
25
|
+
# @return [string]
|
26
|
+
def notebook_type
|
27
|
+
attributes.fetch(:notebookType)
|
28
|
+
end
|
29
|
+
|
30
|
+
#
|
31
|
+
# A Uri [scheme](#Uri.scheme), like `file` or `untitled`. */
|
32
|
+
#
|
33
|
+
# @return [string | nil]
|
34
|
+
def scheme
|
35
|
+
attributes.fetch(:scheme)
|
36
|
+
end
|
37
|
+
|
38
|
+
#
|
39
|
+
# A glob pattern. */
|
40
|
+
#
|
41
|
+
# @return [string | nil]
|
42
|
+
def pattern
|
43
|
+
attributes.fetch(:pattern)
|
44
|
+
end
|
45
|
+
|
46
|
+
attr_reader :attributes
|
47
|
+
|
48
|
+
def to_hash
|
49
|
+
attributes
|
50
|
+
end
|
51
|
+
|
52
|
+
def to_json(*args)
|
53
|
+
to_hash.to_json(*args)
|
54
|
+
end
|
55
|
+
end
|
56
|
+
end
|
57
|
+
end
|
58
|
+
end
|
@@ -0,0 +1,38 @@
|
|
1
|
+
module LanguageServer
|
2
|
+
module Protocol
|
3
|
+
module Interface
|
4
|
+
#
|
5
|
+
# A literal to identify a notebook document in the client.
|
6
|
+
#
|
7
|
+
# @since 3.17.0
|
8
|
+
#
|
9
|
+
class NotebookDocumentIdentifier
|
10
|
+
def initialize(uri:)
|
11
|
+
@attributes = {}
|
12
|
+
|
13
|
+
@attributes[:uri] = uri
|
14
|
+
|
15
|
+
@attributes.freeze
|
16
|
+
end
|
17
|
+
|
18
|
+
#
|
19
|
+
# The notebook document's uri.
|
20
|
+
#
|
21
|
+
# @return [URI]
|
22
|
+
def uri
|
23
|
+
attributes.fetch(:uri)
|
24
|
+
end
|
25
|
+
|
26
|
+
attr_reader :attributes
|
27
|
+
|
28
|
+
def to_hash
|
29
|
+
attributes
|
30
|
+
end
|
31
|
+
|
32
|
+
def to_json(*args)
|
33
|
+
to_hash.to_json(*args)
|
34
|
+
end
|
35
|
+
end
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|