1#![cfg_attr(rustfmt, rustfmt_skip)]
4#![allow(clippy::large_enum_variant)]
5#![allow(clippy::enum_variant_names)]
6#![allow(clippy::upper_case_acronyms)]
7#![allow(clippy::doc_lazy_continuation)]
8#![allow(clippy::derive_partial_eq_without_eq)]
9#![allow(dead_code)]
10#![allow(unused_imports)]
11#![allow(non_upper_case_globals)]
12use serde::{Deserialize, Serialize};
13use serde_json::Value as LspAny;
14pub const LSP_SPEC_VERSION: &str = "3.18.0";
15pub type URI = String;
16pub type DocumentUri = String;
17pub type RegExp = String;
18pub type Integer = i32;
19pub type Uinteger = u32;
20pub type Decimal = f64;
21pub type Definition = LocationOrLocationArray;
28pub type DefinitionLink = LocationLink;
33pub type LSPArray = Vec<LSPAny>;
36pub type LSPAny = Option<
43 BooleanOrDecimalOrIntegerOrLSPArrayOrLSPObjectOrStringOrUinteger,
44>;
45pub type Declaration = LocationOrLocationArray;
47pub type DeclarationLink = LocationLink;
55pub type InlineValue = InlineValueEvaluatableExpressionOrInlineValueTextOrInlineValueVariableLookup;
63pub type DocumentDiagnosticReport = RelatedFullDocumentDiagnosticReportOrRelatedUnchangedDocumentDiagnosticReport;
71pub type PrepareRenameResult = PrepareRenameDefaultBehaviorOrPrepareRenamePlaceholderOrRange;
72pub type DocumentSelector = Vec<DocumentFilter>;
78pub type ProgressToken = IntegerOrString;
79pub type ChangeAnnotationIdentifier = String;
81pub type WorkspaceDocumentDiagnosticReport = WorkspaceFullDocumentDiagnosticReportOrWorkspaceUnchangedDocumentDiagnosticReport;
85pub type TextDocumentContentChangeEvent = TextDocumentContentChangePartialOrTextDocumentContentChangeWholeDocument;
88pub type MarkedString = MarkedStringWithLanguageOrString;
101pub type DocumentFilter = NotebookCellTextDocumentFilterOrTextDocumentFilter;
106pub type LSPObject = std::collections::BTreeMap<String, LSPAny>;
109pub type GlobPattern = PatternOrRelativePattern;
113#[doc = "A document filter denotes a document by different properties like\nthe {@link TextDocument.languageId language}, the {@link Uri.scheme scheme} of\nits resource, or a glob-pattern that is applied to the {@link TextDocument.fileName path}.\n\nGlob patterns can have the following syntax:\n- `*` to match zero or more characters in a path segment\n- `?` to match on one character in a path segment\n- `**` to match any number of path segments, including none\n- `{}` to group sub patterns into an OR expression. (e.g. `**\u{200b}/*.{ts,js}` matches all TypeScript and JavaScript files)\n- `[]` to declare a range of characters to match in a path segment (e.g., `example.[0-9]` to match on `example.0`, `example.1`, …)\n- `[!...]` to negate a range of characters to match in a path segment (e.g., `example.[!0-9]` to match on `example.a`, `example.b`, but not `example.0`)\n\n@sample A language filter that applies to typescript files on disk: `{ language: 'typescript', scheme: 'file' }`\n@sample A language filter that applies to all package.json paths: `{ language: 'json', pattern: '**package.json' }`\n\n@since 3.17.0"]
114pub type TextDocumentFilter = TextDocumentFilterLanguageOrTextDocumentFilterPatternOrTextDocumentFilterScheme;
115pub type NotebookDocumentFilter = NotebookDocumentFilterNotebookTypeOrNotebookDocumentFilterPatternOrNotebookDocumentFilterScheme;
121#[doc = "The glob pattern to watch relative to the base path. Glob patterns can have the following syntax:\n- `*` to match zero or more characters in a path segment\n- `?` to match on one character in a path segment\n- `**` to match any number of path segments, including none\n- `{}` to group conditions (e.g. `**\u{200b}/*.{ts,js}` matches all TypeScript and JavaScript files)\n- `[]` to declare a range of characters to match in a path segment (e.g., `example.[0-9]` to match on `example.0`, `example.1`, …)\n- `[!...]` to negate a range of characters to match in a path segment (e.g., `example.[!0-9]` to match on `example.a`, `example.b`, but not `example.0`)\n\n@since 3.17.0"]
122pub type Pattern = String;
123pub type RegularExpressionEngineKind = String;
124#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
130#[serde(transparent)]
131pub struct SemanticTokenTypes(pub String);
132impl SemanticTokenTypes {
133 pub const NAMESPACE: &'static str = "namespace";
134 pub const TYPE: &'static str = "type";
135 pub const CLASS: &'static str = "class";
136 pub const ENUM: &'static str = "enum";
137 pub const INTERFACE: &'static str = "interface";
138 pub const STRUCT: &'static str = "struct";
139 pub const TYPE_PARAMETER: &'static str = "typeParameter";
140 pub const PARAMETER: &'static str = "parameter";
141 pub const VARIABLE: &'static str = "variable";
142 pub const PROPERTY: &'static str = "property";
143 pub const ENUM_MEMBER: &'static str = "enumMember";
144 pub const EVENT: &'static str = "event";
145 pub const FUNCTION: &'static str = "function";
146 pub const METHOD: &'static str = "method";
147 pub const MACRO: &'static str = "macro";
148 pub const KEYWORD: &'static str = "keyword";
149 pub const MODIFIER: &'static str = "modifier";
150 pub const COMMENT: &'static str = "comment";
151 pub const STRING: &'static str = "string";
152 pub const NUMBER: &'static str = "number";
153 pub const REGEXP: &'static str = "regexp";
154 pub const OPERATOR: &'static str = "operator";
155 pub const DECORATOR: &'static str = "decorator";
156 pub const LABEL: &'static str = "label";
157}
158#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
164#[serde(transparent)]
165pub struct SemanticTokenModifiers(pub String);
166impl SemanticTokenModifiers {
167 pub const DECLARATION: &'static str = "declaration";
168 pub const DEFINITION: &'static str = "definition";
169 pub const READONLY: &'static str = "readonly";
170 pub const STATIC: &'static str = "static";
171 pub const DEPRECATED: &'static str = "deprecated";
172 pub const ABSTRACT: &'static str = "abstract";
173 pub const ASYNC: &'static str = "async";
174 pub const MODIFICATION: &'static str = "modification";
175 pub const DOCUMENTATION: &'static str = "documentation";
176 pub const DEFAULT_LIBRARY: &'static str = "defaultLibrary";
177}
178#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize)]
182pub enum DocumentDiagnosticReportKind {
183 #[serde(rename = "full")]
186 Full,
187 #[serde(rename = "unchanged")]
190 Unchanged,
191}
192#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
194#[serde(transparent)]
195pub struct ErrorCodes(pub i32);
196impl ErrorCodes {
197 pub const PARSE_ERROR: i32 = -32700;
198 pub const INVALID_REQUEST: i32 = -32600;
199 pub const METHOD_NOT_FOUND: i32 = -32601;
200 pub const INVALID_PARAMS: i32 = -32602;
201 pub const INTERNAL_ERROR: i32 = -32603;
202 pub const SERVER_NOT_INITIALIZED: i32 = -32002;
203 pub const UNKNOWN_ERROR_CODE: i32 = -32001;
204}
205#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
206#[serde(transparent)]
207pub struct LSPErrorCodes(pub i32);
208impl LSPErrorCodes {
209 pub const REQUEST_FAILED: i32 = -32803;
210 pub const SERVER_CANCELLED: i32 = -32802;
211 pub const CONTENT_MODIFIED: i32 = -32801;
212 pub const REQUEST_CANCELLED: i32 = -32800;
213}
214#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
216#[serde(transparent)]
217pub struct FoldingRangeKind(pub String);
218impl FoldingRangeKind {
219 pub const COMMENT: &'static str = "comment";
220 pub const IMPORTS: &'static str = "imports";
221 pub const REGION: &'static str = "region";
222}
223#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
225pub enum SymbolKind {
226 File,
227 Module,
228 Namespace,
229 Package,
230 Class,
231 Method,
232 Property,
233 Field,
234 Constructor,
235 Enum,
236 Interface,
237 Function,
238 Variable,
239 Constant,
240 String,
241 Number,
242 Boolean,
243 Array,
244 Object,
245 Key,
246 Null,
247 EnumMember,
248 Struct,
249 Event,
250 Operator,
251 TypeParameter,
252}
253impl serde::Serialize for SymbolKind {
254 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
255 where
256 S: serde::Serializer,
257 {
258 match self {
259 Self::File => serializer.serialize_i64(1i64),
260 Self::Module => serializer.serialize_i64(2i64),
261 Self::Namespace => serializer.serialize_i64(3i64),
262 Self::Package => serializer.serialize_i64(4i64),
263 Self::Class => serializer.serialize_i64(5i64),
264 Self::Method => serializer.serialize_i64(6i64),
265 Self::Property => serializer.serialize_i64(7i64),
266 Self::Field => serializer.serialize_i64(8i64),
267 Self::Constructor => serializer.serialize_i64(9i64),
268 Self::Enum => serializer.serialize_i64(10i64),
269 Self::Interface => serializer.serialize_i64(11i64),
270 Self::Function => serializer.serialize_i64(12i64),
271 Self::Variable => serializer.serialize_i64(13i64),
272 Self::Constant => serializer.serialize_i64(14i64),
273 Self::String => serializer.serialize_i64(15i64),
274 Self::Number => serializer.serialize_i64(16i64),
275 Self::Boolean => serializer.serialize_i64(17i64),
276 Self::Array => serializer.serialize_i64(18i64),
277 Self::Object => serializer.serialize_i64(19i64),
278 Self::Key => serializer.serialize_i64(20i64),
279 Self::Null => serializer.serialize_i64(21i64),
280 Self::EnumMember => serializer.serialize_i64(22i64),
281 Self::Struct => serializer.serialize_i64(23i64),
282 Self::Event => serializer.serialize_i64(24i64),
283 Self::Operator => serializer.serialize_i64(25i64),
284 Self::TypeParameter => serializer.serialize_i64(26i64),
285 }
286 }
287}
288impl<'de> serde::Deserialize<'de> for SymbolKind {
289 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
290 where
291 D: serde::Deserializer<'de>,
292 {
293 struct Visitor;
294 impl<'de> serde::de::Visitor<'de> for Visitor {
295 type Value = SymbolKind;
296 fn expecting(
297 &self,
298 formatter: &mut std::fmt::Formatter,
299 ) -> std::fmt::Result {
300 formatter.write_str("a number representing the enum")
301 }
302 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
303 where
304 E: serde::de::Error,
305 {
306 match value {
307 1i64 => Ok(SymbolKind::File),
308 2i64 => Ok(SymbolKind::Module),
309 3i64 => Ok(SymbolKind::Namespace),
310 4i64 => Ok(SymbolKind::Package),
311 5i64 => Ok(SymbolKind::Class),
312 6i64 => Ok(SymbolKind::Method),
313 7i64 => Ok(SymbolKind::Property),
314 8i64 => Ok(SymbolKind::Field),
315 9i64 => Ok(SymbolKind::Constructor),
316 10i64 => Ok(SymbolKind::Enum),
317 11i64 => Ok(SymbolKind::Interface),
318 12i64 => Ok(SymbolKind::Function),
319 13i64 => Ok(SymbolKind::Variable),
320 14i64 => Ok(SymbolKind::Constant),
321 15i64 => Ok(SymbolKind::String),
322 16i64 => Ok(SymbolKind::Number),
323 17i64 => Ok(SymbolKind::Boolean),
324 18i64 => Ok(SymbolKind::Array),
325 19i64 => Ok(SymbolKind::Object),
326 20i64 => Ok(SymbolKind::Key),
327 21i64 => Ok(SymbolKind::Null),
328 22i64 => Ok(SymbolKind::EnumMember),
329 23i64 => Ok(SymbolKind::Struct),
330 24i64 => Ok(SymbolKind::Event),
331 25i64 => Ok(SymbolKind::Operator),
332 26i64 => Ok(SymbolKind::TypeParameter),
333 _ => Err(E::custom(format!("unknown variant: {}", value))),
334 }
335 }
336 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
337 where
338 E: serde::de::Error,
339 {
340 self.visit_i64(value as i64)
341 }
342 }
343 deserializer.deserialize_i64(Visitor)
344 }
345}
346#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
350pub enum SymbolTag {
351 Deprecated,
353}
354impl serde::Serialize for SymbolTag {
355 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
356 where
357 S: serde::Serializer,
358 {
359 match self {
360 Self::Deprecated => serializer.serialize_i64(1i64),
361 }
362 }
363}
364impl<'de> serde::Deserialize<'de> for SymbolTag {
365 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
366 where
367 D: serde::Deserializer<'de>,
368 {
369 struct Visitor;
370 impl<'de> serde::de::Visitor<'de> for Visitor {
371 type Value = SymbolTag;
372 fn expecting(
373 &self,
374 formatter: &mut std::fmt::Formatter,
375 ) -> std::fmt::Result {
376 formatter.write_str("a number representing the enum")
377 }
378 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
379 where
380 E: serde::de::Error,
381 {
382 match value {
383 1i64 => Ok(SymbolTag::Deprecated),
384 _ => Err(E::custom(format!("unknown variant: {}", value))),
385 }
386 }
387 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
388 where
389 E: serde::de::Error,
390 {
391 self.visit_i64(value as i64)
392 }
393 }
394 deserializer.deserialize_i64(Visitor)
395 }
396}
397#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize)]
401pub enum UniquenessLevel {
402 #[serde(rename = "document")]
404 Document,
405 #[serde(rename = "project")]
407 Project,
408 #[serde(rename = "group")]
410 Group,
411 #[serde(rename = "scheme")]
413 Scheme,
414 #[serde(rename = "global")]
416 Global,
417}
418#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize)]
422pub enum MonikerKind {
423 #[serde(rename = "import")]
425 Import,
426 #[serde(rename = "export")]
428 Export,
429 #[serde(rename = "local")]
432 Local,
433}
434#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
438pub enum InlayHintKind {
439 Type,
441 Parameter,
443}
444impl serde::Serialize for InlayHintKind {
445 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
446 where
447 S: serde::Serializer,
448 {
449 match self {
450 Self::Type => serializer.serialize_i64(1i64),
451 Self::Parameter => serializer.serialize_i64(2i64),
452 }
453 }
454}
455impl<'de> serde::Deserialize<'de> for InlayHintKind {
456 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
457 where
458 D: serde::Deserializer<'de>,
459 {
460 struct Visitor;
461 impl<'de> serde::de::Visitor<'de> for Visitor {
462 type Value = InlayHintKind;
463 fn expecting(
464 &self,
465 formatter: &mut std::fmt::Formatter,
466 ) -> std::fmt::Result {
467 formatter.write_str("a number representing the enum")
468 }
469 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
470 where
471 E: serde::de::Error,
472 {
473 match value {
474 1i64 => Ok(InlayHintKind::Type),
475 2i64 => Ok(InlayHintKind::Parameter),
476 _ => Err(E::custom(format!("unknown variant: {}", value))),
477 }
478 }
479 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
480 where
481 E: serde::de::Error,
482 {
483 self.visit_i64(value as i64)
484 }
485 }
486 deserializer.deserialize_i64(Visitor)
487 }
488}
489#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
491pub enum MessageType {
492 Error,
494 Warning,
496 Info,
498 Log,
500 Debug,
504}
505impl serde::Serialize for MessageType {
506 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
507 where
508 S: serde::Serializer,
509 {
510 match self {
511 Self::Error => serializer.serialize_i64(1i64),
512 Self::Warning => serializer.serialize_i64(2i64),
513 Self::Info => serializer.serialize_i64(3i64),
514 Self::Log => serializer.serialize_i64(4i64),
515 Self::Debug => serializer.serialize_i64(5i64),
516 }
517 }
518}
519impl<'de> serde::Deserialize<'de> for MessageType {
520 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
521 where
522 D: serde::Deserializer<'de>,
523 {
524 struct Visitor;
525 impl<'de> serde::de::Visitor<'de> for Visitor {
526 type Value = MessageType;
527 fn expecting(
528 &self,
529 formatter: &mut std::fmt::Formatter,
530 ) -> std::fmt::Result {
531 formatter.write_str("a number representing the enum")
532 }
533 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
534 where
535 E: serde::de::Error,
536 {
537 match value {
538 1i64 => Ok(MessageType::Error),
539 2i64 => Ok(MessageType::Warning),
540 3i64 => Ok(MessageType::Info),
541 4i64 => Ok(MessageType::Log),
542 5i64 => Ok(MessageType::Debug),
543 _ => Err(E::custom(format!("unknown variant: {}", value))),
544 }
545 }
546 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
547 where
548 E: serde::de::Error,
549 {
550 self.visit_i64(value as i64)
551 }
552 }
553 deserializer.deserialize_i64(Visitor)
554 }
555}
556#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
559pub enum TextDocumentSyncKind {
560 None,
562 Full,
565 Incremental,
569}
570impl serde::Serialize for TextDocumentSyncKind {
571 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
572 where
573 S: serde::Serializer,
574 {
575 match self {
576 Self::None => serializer.serialize_i64(0i64),
577 Self::Full => serializer.serialize_i64(1i64),
578 Self::Incremental => serializer.serialize_i64(2i64),
579 }
580 }
581}
582impl<'de> serde::Deserialize<'de> for TextDocumentSyncKind {
583 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
584 where
585 D: serde::Deserializer<'de>,
586 {
587 struct Visitor;
588 impl<'de> serde::de::Visitor<'de> for Visitor {
589 type Value = TextDocumentSyncKind;
590 fn expecting(
591 &self,
592 formatter: &mut std::fmt::Formatter,
593 ) -> std::fmt::Result {
594 formatter.write_str("a number representing the enum")
595 }
596 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
597 where
598 E: serde::de::Error,
599 {
600 match value {
601 0i64 => Ok(TextDocumentSyncKind::None),
602 1i64 => Ok(TextDocumentSyncKind::Full),
603 2i64 => Ok(TextDocumentSyncKind::Incremental),
604 _ => Err(E::custom(format!("unknown variant: {}", value))),
605 }
606 }
607 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
608 where
609 E: serde::de::Error,
610 {
611 self.visit_i64(value as i64)
612 }
613 }
614 deserializer.deserialize_i64(Visitor)
615 }
616}
617#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
619pub enum TextDocumentSaveReason {
620 Manual,
623 AfterDelay,
625 FocusOut,
627}
628impl serde::Serialize for TextDocumentSaveReason {
629 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
630 where
631 S: serde::Serializer,
632 {
633 match self {
634 Self::Manual => serializer.serialize_i64(1i64),
635 Self::AfterDelay => serializer.serialize_i64(2i64),
636 Self::FocusOut => serializer.serialize_i64(3i64),
637 }
638 }
639}
640impl<'de> serde::Deserialize<'de> for TextDocumentSaveReason {
641 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
642 where
643 D: serde::Deserializer<'de>,
644 {
645 struct Visitor;
646 impl<'de> serde::de::Visitor<'de> for Visitor {
647 type Value = TextDocumentSaveReason;
648 fn expecting(
649 &self,
650 formatter: &mut std::fmt::Formatter,
651 ) -> std::fmt::Result {
652 formatter.write_str("a number representing the enum")
653 }
654 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
655 where
656 E: serde::de::Error,
657 {
658 match value {
659 1i64 => Ok(TextDocumentSaveReason::Manual),
660 2i64 => Ok(TextDocumentSaveReason::AfterDelay),
661 3i64 => Ok(TextDocumentSaveReason::FocusOut),
662 _ => Err(E::custom(format!("unknown variant: {}", value))),
663 }
664 }
665 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
666 where
667 E: serde::de::Error,
668 {
669 self.visit_i64(value as i64)
670 }
671 }
672 deserializer.deserialize_i64(Visitor)
673 }
674}
675#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
677pub enum CompletionItemKind {
678 Text,
679 Method,
680 Function,
681 Constructor,
682 Field,
683 Variable,
684 Class,
685 Interface,
686 Module,
687 Property,
688 Unit,
689 Value,
690 Enum,
691 Keyword,
692 Snippet,
693 Color,
694 File,
695 Reference,
696 Folder,
697 EnumMember,
698 Constant,
699 Struct,
700 Event,
701 Operator,
702 TypeParameter,
703}
704impl serde::Serialize for CompletionItemKind {
705 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
706 where
707 S: serde::Serializer,
708 {
709 match self {
710 Self::Text => serializer.serialize_i64(1i64),
711 Self::Method => serializer.serialize_i64(2i64),
712 Self::Function => serializer.serialize_i64(3i64),
713 Self::Constructor => serializer.serialize_i64(4i64),
714 Self::Field => serializer.serialize_i64(5i64),
715 Self::Variable => serializer.serialize_i64(6i64),
716 Self::Class => serializer.serialize_i64(7i64),
717 Self::Interface => serializer.serialize_i64(8i64),
718 Self::Module => serializer.serialize_i64(9i64),
719 Self::Property => serializer.serialize_i64(10i64),
720 Self::Unit => serializer.serialize_i64(11i64),
721 Self::Value => serializer.serialize_i64(12i64),
722 Self::Enum => serializer.serialize_i64(13i64),
723 Self::Keyword => serializer.serialize_i64(14i64),
724 Self::Snippet => serializer.serialize_i64(15i64),
725 Self::Color => serializer.serialize_i64(16i64),
726 Self::File => serializer.serialize_i64(17i64),
727 Self::Reference => serializer.serialize_i64(18i64),
728 Self::Folder => serializer.serialize_i64(19i64),
729 Self::EnumMember => serializer.serialize_i64(20i64),
730 Self::Constant => serializer.serialize_i64(21i64),
731 Self::Struct => serializer.serialize_i64(22i64),
732 Self::Event => serializer.serialize_i64(23i64),
733 Self::Operator => serializer.serialize_i64(24i64),
734 Self::TypeParameter => serializer.serialize_i64(25i64),
735 }
736 }
737}
738impl<'de> serde::Deserialize<'de> for CompletionItemKind {
739 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
740 where
741 D: serde::Deserializer<'de>,
742 {
743 struct Visitor;
744 impl<'de> serde::de::Visitor<'de> for Visitor {
745 type Value = CompletionItemKind;
746 fn expecting(
747 &self,
748 formatter: &mut std::fmt::Formatter,
749 ) -> std::fmt::Result {
750 formatter.write_str("a number representing the enum")
751 }
752 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
753 where
754 E: serde::de::Error,
755 {
756 match value {
757 1i64 => Ok(CompletionItemKind::Text),
758 2i64 => Ok(CompletionItemKind::Method),
759 3i64 => Ok(CompletionItemKind::Function),
760 4i64 => Ok(CompletionItemKind::Constructor),
761 5i64 => Ok(CompletionItemKind::Field),
762 6i64 => Ok(CompletionItemKind::Variable),
763 7i64 => Ok(CompletionItemKind::Class),
764 8i64 => Ok(CompletionItemKind::Interface),
765 9i64 => Ok(CompletionItemKind::Module),
766 10i64 => Ok(CompletionItemKind::Property),
767 11i64 => Ok(CompletionItemKind::Unit),
768 12i64 => Ok(CompletionItemKind::Value),
769 13i64 => Ok(CompletionItemKind::Enum),
770 14i64 => Ok(CompletionItemKind::Keyword),
771 15i64 => Ok(CompletionItemKind::Snippet),
772 16i64 => Ok(CompletionItemKind::Color),
773 17i64 => Ok(CompletionItemKind::File),
774 18i64 => Ok(CompletionItemKind::Reference),
775 19i64 => Ok(CompletionItemKind::Folder),
776 20i64 => Ok(CompletionItemKind::EnumMember),
777 21i64 => Ok(CompletionItemKind::Constant),
778 22i64 => Ok(CompletionItemKind::Struct),
779 23i64 => Ok(CompletionItemKind::Event),
780 24i64 => Ok(CompletionItemKind::Operator),
781 25i64 => Ok(CompletionItemKind::TypeParameter),
782 _ => Err(E::custom(format!("unknown variant: {}", value))),
783 }
784 }
785 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
786 where
787 E: serde::de::Error,
788 {
789 self.visit_i64(value as i64)
790 }
791 }
792 deserializer.deserialize_i64(Visitor)
793 }
794}
795#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
800pub enum CompletionItemTag {
801 Deprecated,
803}
804impl serde::Serialize for CompletionItemTag {
805 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
806 where
807 S: serde::Serializer,
808 {
809 match self {
810 Self::Deprecated => serializer.serialize_i64(1i64),
811 }
812 }
813}
814impl<'de> serde::Deserialize<'de> for CompletionItemTag {
815 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
816 where
817 D: serde::Deserializer<'de>,
818 {
819 struct Visitor;
820 impl<'de> serde::de::Visitor<'de> for Visitor {
821 type Value = CompletionItemTag;
822 fn expecting(
823 &self,
824 formatter: &mut std::fmt::Formatter,
825 ) -> std::fmt::Result {
826 formatter.write_str("a number representing the enum")
827 }
828 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
829 where
830 E: serde::de::Error,
831 {
832 match value {
833 1i64 => Ok(CompletionItemTag::Deprecated),
834 _ => Err(E::custom(format!("unknown variant: {}", value))),
835 }
836 }
837 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
838 where
839 E: serde::de::Error,
840 {
841 self.visit_i64(value as i64)
842 }
843 }
844 deserializer.deserialize_i64(Visitor)
845 }
846}
847#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
850pub enum InsertTextFormat {
851 PlainText,
853 Snippet,
862}
863impl serde::Serialize for InsertTextFormat {
864 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
865 where
866 S: serde::Serializer,
867 {
868 match self {
869 Self::PlainText => serializer.serialize_i64(1i64),
870 Self::Snippet => serializer.serialize_i64(2i64),
871 }
872 }
873}
874impl<'de> serde::Deserialize<'de> for InsertTextFormat {
875 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
876 where
877 D: serde::Deserializer<'de>,
878 {
879 struct Visitor;
880 impl<'de> serde::de::Visitor<'de> for Visitor {
881 type Value = InsertTextFormat;
882 fn expecting(
883 &self,
884 formatter: &mut std::fmt::Formatter,
885 ) -> std::fmt::Result {
886 formatter.write_str("a number representing the enum")
887 }
888 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
889 where
890 E: serde::de::Error,
891 {
892 match value {
893 1i64 => Ok(InsertTextFormat::PlainText),
894 2i64 => Ok(InsertTextFormat::Snippet),
895 _ => Err(E::custom(format!("unknown variant: {}", value))),
896 }
897 }
898 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
899 where
900 E: serde::de::Error,
901 {
902 self.visit_i64(value as i64)
903 }
904 }
905 deserializer.deserialize_i64(Visitor)
906 }
907}
908#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
913pub enum InsertTextMode {
914 AsIs,
920 AdjustIndentation,
928}
929impl serde::Serialize for InsertTextMode {
930 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
931 where
932 S: serde::Serializer,
933 {
934 match self {
935 Self::AsIs => serializer.serialize_i64(1i64),
936 Self::AdjustIndentation => serializer.serialize_i64(2i64),
937 }
938 }
939}
940impl<'de> serde::Deserialize<'de> for InsertTextMode {
941 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
942 where
943 D: serde::Deserializer<'de>,
944 {
945 struct Visitor;
946 impl<'de> serde::de::Visitor<'de> for Visitor {
947 type Value = InsertTextMode;
948 fn expecting(
949 &self,
950 formatter: &mut std::fmt::Formatter,
951 ) -> std::fmt::Result {
952 formatter.write_str("a number representing the enum")
953 }
954 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
955 where
956 E: serde::de::Error,
957 {
958 match value {
959 1i64 => Ok(InsertTextMode::AsIs),
960 2i64 => Ok(InsertTextMode::AdjustIndentation),
961 _ => Err(E::custom(format!("unknown variant: {}", value))),
962 }
963 }
964 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
965 where
966 E: serde::de::Error,
967 {
968 self.visit_i64(value as i64)
969 }
970 }
971 deserializer.deserialize_i64(Visitor)
972 }
973}
974#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
976pub enum DocumentHighlightKind {
977 Text,
979 Read,
981 Write,
983}
984impl serde::Serialize for DocumentHighlightKind {
985 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
986 where
987 S: serde::Serializer,
988 {
989 match self {
990 Self::Text => serializer.serialize_i64(1i64),
991 Self::Read => serializer.serialize_i64(2i64),
992 Self::Write => serializer.serialize_i64(3i64),
993 }
994 }
995}
996impl<'de> serde::Deserialize<'de> for DocumentHighlightKind {
997 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
998 where
999 D: serde::Deserializer<'de>,
1000 {
1001 struct Visitor;
1002 impl<'de> serde::de::Visitor<'de> for Visitor {
1003 type Value = DocumentHighlightKind;
1004 fn expecting(
1005 &self,
1006 formatter: &mut std::fmt::Formatter,
1007 ) -> std::fmt::Result {
1008 formatter.write_str("a number representing the enum")
1009 }
1010 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
1011 where
1012 E: serde::de::Error,
1013 {
1014 match value {
1015 1i64 => Ok(DocumentHighlightKind::Text),
1016 2i64 => Ok(DocumentHighlightKind::Read),
1017 3i64 => Ok(DocumentHighlightKind::Write),
1018 _ => Err(E::custom(format!("unknown variant: {}", value))),
1019 }
1020 }
1021 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
1022 where
1023 E: serde::de::Error,
1024 {
1025 self.visit_i64(value as i64)
1026 }
1027 }
1028 deserializer.deserialize_i64(Visitor)
1029 }
1030}
1031#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
1033#[serde(transparent)]
1034pub struct CodeActionKind(pub String);
1035impl CodeActionKind {
1036 pub const EMPTY: &'static str = "";
1037 pub const QUICK_FIX: &'static str = "quickfix";
1038 pub const REFACTOR: &'static str = "refactor";
1039 pub const REFACTOR_EXTRACT: &'static str = "refactor.extract";
1040 pub const REFACTOR_INLINE: &'static str = "refactor.inline";
1041 pub const REFACTOR_MOVE: &'static str = "refactor.move";
1042 pub const REFACTOR_REWRITE: &'static str = "refactor.rewrite";
1043 pub const SOURCE: &'static str = "source";
1044 pub const SOURCE_ORGANIZE_IMPORTS: &'static str = "source.organizeImports";
1045 pub const SOURCE_FIX_ALL: &'static str = "source.fixAll";
1046 pub const NOTEBOOK: &'static str = "notebook";
1047}
1048#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
1052pub enum CodeActionTag {
1053 LlmGenerated,
1055}
1056impl serde::Serialize for CodeActionTag {
1057 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
1058 where
1059 S: serde::Serializer,
1060 {
1061 match self {
1062 Self::LlmGenerated => serializer.serialize_i64(1i64),
1063 }
1064 }
1065}
1066impl<'de> serde::Deserialize<'de> for CodeActionTag {
1067 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
1068 where
1069 D: serde::Deserializer<'de>,
1070 {
1071 struct Visitor;
1072 impl<'de> serde::de::Visitor<'de> for Visitor {
1073 type Value = CodeActionTag;
1074 fn expecting(
1075 &self,
1076 formatter: &mut std::fmt::Formatter,
1077 ) -> std::fmt::Result {
1078 formatter.write_str("a number representing the enum")
1079 }
1080 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
1081 where
1082 E: serde::de::Error,
1083 {
1084 match value {
1085 1i64 => Ok(CodeActionTag::LlmGenerated),
1086 _ => Err(E::custom(format!("unknown variant: {}", value))),
1087 }
1088 }
1089 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
1090 where
1091 E: serde::de::Error,
1092 {
1093 self.visit_i64(value as i64)
1094 }
1095 }
1096 deserializer.deserialize_i64(Visitor)
1097 }
1098}
1099#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize)]
1100pub enum TraceValue {
1101 #[serde(rename = "off")]
1103 Off,
1104 #[serde(rename = "messages")]
1106 Messages,
1107 #[serde(rename = "verbose")]
1109 Verbose,
1110}
1111#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize)]
1117pub enum MarkupKind {
1118 #[serde(rename = "plaintext")]
1120 PlainText,
1121 #[serde(rename = "markdown")]
1123 Markdown,
1124}
1125#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
1128#[serde(transparent)]
1129pub struct LanguageKind(pub String);
1130impl LanguageKind {
1131 pub const ABAP: &'static str = "abap";
1132 pub const WINDOWS_BAT: &'static str = "bat";
1133 pub const BIB_TE_X: &'static str = "bibtex";
1134 pub const CLOJURE: &'static str = "clojure";
1135 pub const COFFEESCRIPT: &'static str = "coffeescript";
1136 pub const C: &'static str = "c";
1137 pub const CPP: &'static str = "cpp";
1138 pub const C_SHARP: &'static str = "csharp";
1139 pub const CSS: &'static str = "css";
1140 pub const D: &'static str = "d";
1141 pub const DELPHI: &'static str = "pascal";
1142 pub const DIFF: &'static str = "diff";
1143 pub const DART: &'static str = "dart";
1144 pub const DOCKERFILE: &'static str = "dockerfile";
1145 pub const ELIXIR: &'static str = "elixir";
1146 pub const ERLANG: &'static str = "erlang";
1147 pub const F_SHARP: &'static str = "fsharp";
1148 pub const GIT_COMMIT: &'static str = "git-commit";
1149 pub const GIT_REBASE: &'static str = "git-rebase";
1150 pub const GO: &'static str = "go";
1151 pub const GROOVY: &'static str = "groovy";
1152 pub const HANDLEBARS: &'static str = "handlebars";
1153 pub const HASKELL: &'static str = "haskell";
1154 pub const HTML: &'static str = "html";
1155 pub const INI: &'static str = "ini";
1156 pub const JAVA: &'static str = "java";
1157 pub const JAVA_SCRIPT: &'static str = "javascript";
1158 pub const JAVA_SCRIPT_REACT: &'static str = "javascriptreact";
1159 pub const JSON: &'static str = "json";
1160 pub const LA_TE_X: &'static str = "latex";
1161 pub const LESS: &'static str = "less";
1162 pub const LUA: &'static str = "lua";
1163 pub const MAKEFILE: &'static str = "makefile";
1164 pub const MARKDOWN: &'static str = "markdown";
1165 pub const OBJECTIVE_C: &'static str = "objective-c";
1166 pub const OBJECTIVE_CPP: &'static str = "objective-cpp";
1167 pub const PASCAL: &'static str = "pascal";
1168 pub const PERL: &'static str = "perl";
1169 pub const PERL6: &'static str = "perl6";
1170 pub const PHP: &'static str = "php";
1171 pub const PLAINTEXT: &'static str = "plaintext";
1172 pub const POWERSHELL: &'static str = "powershell";
1173 pub const PUG: &'static str = "jade";
1174 pub const PYTHON: &'static str = "python";
1175 pub const R: &'static str = "r";
1176 pub const RAZOR: &'static str = "razor";
1177 pub const RUBY: &'static str = "ruby";
1178 pub const RUST: &'static str = "rust";
1179 pub const SCSS: &'static str = "scss";
1180 pub const SASS: &'static str = "sass";
1181 pub const SCALA: &'static str = "scala";
1182 pub const SHADER_LAB: &'static str = "shaderlab";
1183 pub const SHELL_SCRIPT: &'static str = "shellscript";
1184 pub const SQL: &'static str = "sql";
1185 pub const SWIFT: &'static str = "swift";
1186 pub const TYPE_SCRIPT: &'static str = "typescript";
1187 pub const TYPE_SCRIPT_REACT: &'static str = "typescriptreact";
1188 pub const TE_X: &'static str = "tex";
1189 pub const VISUAL_BASIC: &'static str = "vb";
1190 pub const XML: &'static str = "xml";
1191 pub const XSL: &'static str = "xsl";
1192 pub const YAML: &'static str = "yaml";
1193}
1194#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
1198pub enum InlineCompletionTriggerKind {
1199 Invoked,
1201 Automatic,
1203}
1204impl serde::Serialize for InlineCompletionTriggerKind {
1205 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
1206 where
1207 S: serde::Serializer,
1208 {
1209 match self {
1210 Self::Invoked => serializer.serialize_i64(1i64),
1211 Self::Automatic => serializer.serialize_i64(2i64),
1212 }
1213 }
1214}
1215impl<'de> serde::Deserialize<'de> for InlineCompletionTriggerKind {
1216 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
1217 where
1218 D: serde::Deserializer<'de>,
1219 {
1220 struct Visitor;
1221 impl<'de> serde::de::Visitor<'de> for Visitor {
1222 type Value = InlineCompletionTriggerKind;
1223 fn expecting(
1224 &self,
1225 formatter: &mut std::fmt::Formatter,
1226 ) -> std::fmt::Result {
1227 formatter.write_str("a number representing the enum")
1228 }
1229 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
1230 where
1231 E: serde::de::Error,
1232 {
1233 match value {
1234 1i64 => Ok(InlineCompletionTriggerKind::Invoked),
1235 2i64 => Ok(InlineCompletionTriggerKind::Automatic),
1236 _ => Err(E::custom(format!("unknown variant: {}", value))),
1237 }
1238 }
1239 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
1240 where
1241 E: serde::de::Error,
1242 {
1243 self.visit_i64(value as i64)
1244 }
1245 }
1246 deserializer.deserialize_i64(Visitor)
1247 }
1248}
1249#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
1253#[serde(transparent)]
1254pub struct PositionEncodingKind(pub String);
1255impl PositionEncodingKind {
1256 pub const UTF8: &'static str = "utf-8";
1257 pub const UTF16: &'static str = "utf-16";
1258 pub const UTF32: &'static str = "utf-32";
1259}
1260#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
1262pub enum FileChangeType {
1263 Created,
1265 Changed,
1267 Deleted,
1269}
1270impl serde::Serialize for FileChangeType {
1271 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
1272 where
1273 S: serde::Serializer,
1274 {
1275 match self {
1276 Self::Created => serializer.serialize_i64(1i64),
1277 Self::Changed => serializer.serialize_i64(2i64),
1278 Self::Deleted => serializer.serialize_i64(3i64),
1279 }
1280 }
1281}
1282impl<'de> serde::Deserialize<'de> for FileChangeType {
1283 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
1284 where
1285 D: serde::Deserializer<'de>,
1286 {
1287 struct Visitor;
1288 impl<'de> serde::de::Visitor<'de> for Visitor {
1289 type Value = FileChangeType;
1290 fn expecting(
1291 &self,
1292 formatter: &mut std::fmt::Formatter,
1293 ) -> std::fmt::Result {
1294 formatter.write_str("a number representing the enum")
1295 }
1296 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
1297 where
1298 E: serde::de::Error,
1299 {
1300 match value {
1301 1i64 => Ok(FileChangeType::Created),
1302 2i64 => Ok(FileChangeType::Changed),
1303 3i64 => Ok(FileChangeType::Deleted),
1304 _ => Err(E::custom(format!("unknown variant: {}", value))),
1305 }
1306 }
1307 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
1308 where
1309 E: serde::de::Error,
1310 {
1311 self.visit_i64(value as i64)
1312 }
1313 }
1314 deserializer.deserialize_i64(Visitor)
1315 }
1316}
1317#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
1318#[serde(transparent)]
1319pub struct WatchKind(pub u32);
1320impl WatchKind {
1321 pub const CREATE: u32 = 1;
1322 pub const CHANGE: u32 = 2;
1323 pub const DELETE: u32 = 4;
1324}
1325#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
1327pub enum DiagnosticSeverity {
1328 Error,
1330 Warning,
1332 Information,
1334 Hint,
1336}
1337impl serde::Serialize for DiagnosticSeverity {
1338 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
1339 where
1340 S: serde::Serializer,
1341 {
1342 match self {
1343 Self::Error => serializer.serialize_i64(1i64),
1344 Self::Warning => serializer.serialize_i64(2i64),
1345 Self::Information => serializer.serialize_i64(3i64),
1346 Self::Hint => serializer.serialize_i64(4i64),
1347 }
1348 }
1349}
1350impl<'de> serde::Deserialize<'de> for DiagnosticSeverity {
1351 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
1352 where
1353 D: serde::Deserializer<'de>,
1354 {
1355 struct Visitor;
1356 impl<'de> serde::de::Visitor<'de> for Visitor {
1357 type Value = DiagnosticSeverity;
1358 fn expecting(
1359 &self,
1360 formatter: &mut std::fmt::Formatter,
1361 ) -> std::fmt::Result {
1362 formatter.write_str("a number representing the enum")
1363 }
1364 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
1365 where
1366 E: serde::de::Error,
1367 {
1368 match value {
1369 1i64 => Ok(DiagnosticSeverity::Error),
1370 2i64 => Ok(DiagnosticSeverity::Warning),
1371 3i64 => Ok(DiagnosticSeverity::Information),
1372 4i64 => Ok(DiagnosticSeverity::Hint),
1373 _ => Err(E::custom(format!("unknown variant: {}", value))),
1374 }
1375 }
1376 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
1377 where
1378 E: serde::de::Error,
1379 {
1380 self.visit_i64(value as i64)
1381 }
1382 }
1383 deserializer.deserialize_i64(Visitor)
1384 }
1385}
1386#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
1390pub enum DiagnosticTag {
1391 Unnecessary,
1396 Deprecated,
1400}
1401impl serde::Serialize for DiagnosticTag {
1402 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
1403 where
1404 S: serde::Serializer,
1405 {
1406 match self {
1407 Self::Unnecessary => serializer.serialize_i64(1i64),
1408 Self::Deprecated => serializer.serialize_i64(2i64),
1409 }
1410 }
1411}
1412impl<'de> serde::Deserialize<'de> for DiagnosticTag {
1413 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
1414 where
1415 D: serde::Deserializer<'de>,
1416 {
1417 struct Visitor;
1418 impl<'de> serde::de::Visitor<'de> for Visitor {
1419 type Value = DiagnosticTag;
1420 fn expecting(
1421 &self,
1422 formatter: &mut std::fmt::Formatter,
1423 ) -> std::fmt::Result {
1424 formatter.write_str("a number representing the enum")
1425 }
1426 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
1427 where
1428 E: serde::de::Error,
1429 {
1430 match value {
1431 1i64 => Ok(DiagnosticTag::Unnecessary),
1432 2i64 => Ok(DiagnosticTag::Deprecated),
1433 _ => Err(E::custom(format!("unknown variant: {}", value))),
1434 }
1435 }
1436 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
1437 where
1438 E: serde::de::Error,
1439 {
1440 self.visit_i64(value as i64)
1441 }
1442 }
1443 deserializer.deserialize_i64(Visitor)
1444 }
1445}
1446#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
1448pub enum CompletionTriggerKind {
1449 Invoked,
1452 TriggerCharacter,
1455 TriggerForIncompleteCompletions,
1457}
1458impl serde::Serialize for CompletionTriggerKind {
1459 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
1460 where
1461 S: serde::Serializer,
1462 {
1463 match self {
1464 Self::Invoked => serializer.serialize_i64(1i64),
1465 Self::TriggerCharacter => serializer.serialize_i64(2i64),
1466 Self::TriggerForIncompleteCompletions => serializer.serialize_i64(3i64),
1467 }
1468 }
1469}
1470impl<'de> serde::Deserialize<'de> for CompletionTriggerKind {
1471 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
1472 where
1473 D: serde::Deserializer<'de>,
1474 {
1475 struct Visitor;
1476 impl<'de> serde::de::Visitor<'de> for Visitor {
1477 type Value = CompletionTriggerKind;
1478 fn expecting(
1479 &self,
1480 formatter: &mut std::fmt::Formatter,
1481 ) -> std::fmt::Result {
1482 formatter.write_str("a number representing the enum")
1483 }
1484 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
1485 where
1486 E: serde::de::Error,
1487 {
1488 match value {
1489 1i64 => Ok(CompletionTriggerKind::Invoked),
1490 2i64 => Ok(CompletionTriggerKind::TriggerCharacter),
1491 3i64 => Ok(CompletionTriggerKind::TriggerForIncompleteCompletions),
1492 _ => Err(E::custom(format!("unknown variant: {}", value))),
1493 }
1494 }
1495 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
1496 where
1497 E: serde::de::Error,
1498 {
1499 self.visit_i64(value as i64)
1500 }
1501 }
1502 deserializer.deserialize_i64(Visitor)
1503 }
1504}
1505#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
1510pub enum ApplyKind {
1511 Replace,
1514 Merge,
1519}
1520impl serde::Serialize for ApplyKind {
1521 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
1522 where
1523 S: serde::Serializer,
1524 {
1525 match self {
1526 Self::Replace => serializer.serialize_i64(1i64),
1527 Self::Merge => serializer.serialize_i64(2i64),
1528 }
1529 }
1530}
1531impl<'de> serde::Deserialize<'de> for ApplyKind {
1532 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
1533 where
1534 D: serde::Deserializer<'de>,
1535 {
1536 struct Visitor;
1537 impl<'de> serde::de::Visitor<'de> for Visitor {
1538 type Value = ApplyKind;
1539 fn expecting(
1540 &self,
1541 formatter: &mut std::fmt::Formatter,
1542 ) -> std::fmt::Result {
1543 formatter.write_str("a number representing the enum")
1544 }
1545 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
1546 where
1547 E: serde::de::Error,
1548 {
1549 match value {
1550 1i64 => Ok(ApplyKind::Replace),
1551 2i64 => Ok(ApplyKind::Merge),
1552 _ => Err(E::custom(format!("unknown variant: {}", value))),
1553 }
1554 }
1555 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
1556 where
1557 E: serde::de::Error,
1558 {
1559 self.visit_i64(value as i64)
1560 }
1561 }
1562 deserializer.deserialize_i64(Visitor)
1563 }
1564}
1565#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
1569pub enum SignatureHelpTriggerKind {
1570 Invoked,
1572 TriggerCharacter,
1574 ContentChange,
1576}
1577impl serde::Serialize for SignatureHelpTriggerKind {
1578 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
1579 where
1580 S: serde::Serializer,
1581 {
1582 match self {
1583 Self::Invoked => serializer.serialize_i64(1i64),
1584 Self::TriggerCharacter => serializer.serialize_i64(2i64),
1585 Self::ContentChange => serializer.serialize_i64(3i64),
1586 }
1587 }
1588}
1589impl<'de> serde::Deserialize<'de> for SignatureHelpTriggerKind {
1590 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
1591 where
1592 D: serde::Deserializer<'de>,
1593 {
1594 struct Visitor;
1595 impl<'de> serde::de::Visitor<'de> for Visitor {
1596 type Value = SignatureHelpTriggerKind;
1597 fn expecting(
1598 &self,
1599 formatter: &mut std::fmt::Formatter,
1600 ) -> std::fmt::Result {
1601 formatter.write_str("a number representing the enum")
1602 }
1603 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
1604 where
1605 E: serde::de::Error,
1606 {
1607 match value {
1608 1i64 => Ok(SignatureHelpTriggerKind::Invoked),
1609 2i64 => Ok(SignatureHelpTriggerKind::TriggerCharacter),
1610 3i64 => Ok(SignatureHelpTriggerKind::ContentChange),
1611 _ => Err(E::custom(format!("unknown variant: {}", value))),
1612 }
1613 }
1614 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
1615 where
1616 E: serde::de::Error,
1617 {
1618 self.visit_i64(value as i64)
1619 }
1620 }
1621 deserializer.deserialize_i64(Visitor)
1622 }
1623}
1624#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
1628pub enum CodeActionTriggerKind {
1629 Invoked,
1631 Automatic,
1636}
1637impl serde::Serialize for CodeActionTriggerKind {
1638 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
1639 where
1640 S: serde::Serializer,
1641 {
1642 match self {
1643 Self::Invoked => serializer.serialize_i64(1i64),
1644 Self::Automatic => serializer.serialize_i64(2i64),
1645 }
1646 }
1647}
1648impl<'de> serde::Deserialize<'de> for CodeActionTriggerKind {
1649 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
1650 where
1651 D: serde::Deserializer<'de>,
1652 {
1653 struct Visitor;
1654 impl<'de> serde::de::Visitor<'de> for Visitor {
1655 type Value = CodeActionTriggerKind;
1656 fn expecting(
1657 &self,
1658 formatter: &mut std::fmt::Formatter,
1659 ) -> std::fmt::Result {
1660 formatter.write_str("a number representing the enum")
1661 }
1662 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
1663 where
1664 E: serde::de::Error,
1665 {
1666 match value {
1667 1i64 => Ok(CodeActionTriggerKind::Invoked),
1668 2i64 => Ok(CodeActionTriggerKind::Automatic),
1669 _ => Err(E::custom(format!("unknown variant: {}", value))),
1670 }
1671 }
1672 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
1673 where
1674 E: serde::de::Error,
1675 {
1676 self.visit_i64(value as i64)
1677 }
1678 }
1679 deserializer.deserialize_i64(Visitor)
1680 }
1681}
1682#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize)]
1687pub enum FileOperationPatternKind {
1688 #[serde(rename = "file")]
1690 File,
1691 #[serde(rename = "folder")]
1693 Folder,
1694}
1695#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
1699pub enum NotebookCellKind {
1700 Markup,
1702 Code,
1704}
1705impl serde::Serialize for NotebookCellKind {
1706 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
1707 where
1708 S: serde::Serializer,
1709 {
1710 match self {
1711 Self::Markup => serializer.serialize_i64(1i64),
1712 Self::Code => serializer.serialize_i64(2i64),
1713 }
1714 }
1715}
1716impl<'de> serde::Deserialize<'de> for NotebookCellKind {
1717 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
1718 where
1719 D: serde::Deserializer<'de>,
1720 {
1721 struct Visitor;
1722 impl<'de> serde::de::Visitor<'de> for Visitor {
1723 type Value = NotebookCellKind;
1724 fn expecting(
1725 &self,
1726 formatter: &mut std::fmt::Formatter,
1727 ) -> std::fmt::Result {
1728 formatter.write_str("a number representing the enum")
1729 }
1730 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
1731 where
1732 E: serde::de::Error,
1733 {
1734 match value {
1735 1i64 => Ok(NotebookCellKind::Markup),
1736 2i64 => Ok(NotebookCellKind::Code),
1737 _ => Err(E::custom(format!("unknown variant: {}", value))),
1738 }
1739 }
1740 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
1741 where
1742 E: serde::de::Error,
1743 {
1744 self.visit_i64(value as i64)
1745 }
1746 }
1747 deserializer.deserialize_i64(Visitor)
1748 }
1749}
1750#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize)]
1751pub enum ResourceOperationKind {
1752 #[serde(rename = "create")]
1754 Create,
1755 #[serde(rename = "rename")]
1757 Rename,
1758 #[serde(rename = "delete")]
1760 Delete,
1761}
1762#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize)]
1763pub enum FailureHandlingKind {
1764 #[serde(rename = "abort")]
1767 Abort,
1768 #[serde(rename = "transactional")]
1771 Transactional,
1772 #[serde(rename = "textOnlyTransactional")]
1776 TextOnlyTransactional,
1777 #[serde(rename = "undo")]
1780 Undo,
1781}
1782#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
1783pub enum PrepareSupportDefaultBehavior {
1784 Identifier,
1787}
1788impl serde::Serialize for PrepareSupportDefaultBehavior {
1789 fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
1790 where
1791 S: serde::Serializer,
1792 {
1793 match self {
1794 Self::Identifier => serializer.serialize_i64(1i64),
1795 }
1796 }
1797}
1798impl<'de> serde::Deserialize<'de> for PrepareSupportDefaultBehavior {
1799 fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
1800 where
1801 D: serde::Deserializer<'de>,
1802 {
1803 struct Visitor;
1804 impl<'de> serde::de::Visitor<'de> for Visitor {
1805 type Value = PrepareSupportDefaultBehavior;
1806 fn expecting(
1807 &self,
1808 formatter: &mut std::fmt::Formatter,
1809 ) -> std::fmt::Result {
1810 formatter.write_str("a number representing the enum")
1811 }
1812 fn visit_i64<E>(self, value: i64) -> Result<Self::Value, E>
1813 where
1814 E: serde::de::Error,
1815 {
1816 match value {
1817 1i64 => Ok(PrepareSupportDefaultBehavior::Identifier),
1818 _ => Err(E::custom(format!("unknown variant: {}", value))),
1819 }
1820 }
1821 fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
1822 where
1823 E: serde::de::Error,
1824 {
1825 self.visit_i64(value as i64)
1826 }
1827 }
1828 deserializer.deserialize_i64(Visitor)
1829 }
1830}
1831#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize)]
1832pub enum TokenFormat {
1833 #[serde(rename = "relative")]
1834 Relative,
1835}
1836#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1837#[serde(rename_all = "camelCase")]
1838pub struct ImplementationParams {
1839 #[serde(flatten)]
1840 pub text_document_position_params_base: TextDocumentPositionParams,
1841 #[serde(flatten)]
1842 pub work_done_progress_params_mixin: WorkDoneProgressParams,
1843 #[serde(flatten)]
1844 pub partial_result_params_mixin: PartialResultParams,
1845}
1846#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1849#[serde(rename_all = "camelCase")]
1850pub struct Location {
1851 pub uri: DocumentUri,
1852 pub range: Range,
1853}
1854#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1855#[serde(rename_all = "camelCase")]
1856pub struct ImplementationRegistrationOptions {
1857 #[serde(flatten)]
1858 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
1859 #[serde(flatten)]
1860 pub implementation_options_base: ImplementationOptions,
1861 #[serde(flatten)]
1862 pub static_registration_options_mixin: StaticRegistrationOptions,
1863}
1864#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1865#[serde(rename_all = "camelCase")]
1866pub struct TypeDefinitionParams {
1867 #[serde(flatten)]
1868 pub text_document_position_params_base: TextDocumentPositionParams,
1869 #[serde(flatten)]
1870 pub work_done_progress_params_mixin: WorkDoneProgressParams,
1871 #[serde(flatten)]
1872 pub partial_result_params_mixin: PartialResultParams,
1873}
1874#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1875#[serde(rename_all = "camelCase")]
1876pub struct TypeDefinitionRegistrationOptions {
1877 #[serde(flatten)]
1878 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
1879 #[serde(flatten)]
1880 pub type_definition_options_base: TypeDefinitionOptions,
1881 #[serde(flatten)]
1882 pub static_registration_options_mixin: StaticRegistrationOptions,
1883}
1884#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1886#[serde(rename_all = "camelCase")]
1887pub struct WorkspaceFolder {
1888 pub uri: URI,
1890 pub name: String,
1893}
1894#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1896#[serde(rename_all = "camelCase")]
1897pub struct DidChangeWorkspaceFoldersParams {
1898 pub event: WorkspaceFoldersChangeEvent,
1900}
1901#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1903#[serde(rename_all = "camelCase")]
1904pub struct ConfigurationParams {
1905 pub items: Vec<ConfigurationItem>,
1906}
1907#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1909#[serde(rename_all = "camelCase")]
1910pub struct DocumentColorParams {
1911 #[serde(flatten)]
1912 pub work_done_progress_params_mixin: WorkDoneProgressParams,
1913 #[serde(flatten)]
1914 pub partial_result_params_mixin: PartialResultParams,
1915 #[serde(rename = "textDocument")]
1917 pub text_document: TextDocumentIdentifier,
1918}
1919#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1921#[serde(rename_all = "camelCase")]
1922pub struct ColorInformation {
1923 pub range: Range,
1925 pub color: Color,
1927}
1928#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1929#[serde(rename_all = "camelCase")]
1930pub struct DocumentColorRegistrationOptions {
1931 #[serde(flatten)]
1932 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
1933 #[serde(flatten)]
1934 pub document_color_options_base: DocumentColorOptions,
1935 #[serde(flatten)]
1936 pub static_registration_options_mixin: StaticRegistrationOptions,
1937}
1938#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1940#[serde(rename_all = "camelCase")]
1941pub struct ColorPresentationParams {
1942 #[serde(flatten)]
1943 pub work_done_progress_params_mixin: WorkDoneProgressParams,
1944 #[serde(flatten)]
1945 pub partial_result_params_mixin: PartialResultParams,
1946 #[serde(rename = "textDocument")]
1948 pub text_document: TextDocumentIdentifier,
1949 pub color: Color,
1951 pub range: Range,
1953}
1954#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1955#[serde(rename_all = "camelCase")]
1956pub struct ColorPresentation {
1957 pub label: String,
1961 #[serde(rename = "textEdit")]
1965 #[serde(default)]
1966 pub text_edit: Option<TextEdit>,
1967 #[serde(rename = "additionalTextEdits")]
1970 #[serde(default)]
1971 pub additional_text_edits: Option<Vec<TextEdit>>,
1972}
1973#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1974#[serde(rename_all = "camelCase")]
1975pub struct WorkDoneProgressOptions {
1976 #[serde(rename = "workDoneProgress")]
1977 #[serde(default)]
1978 pub work_done_progress: Option<bool>,
1979}
1980#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1982#[serde(rename_all = "camelCase")]
1983pub struct TextDocumentRegistrationOptions {
1984 #[serde(rename = "documentSelector")]
1987 pub document_selector: Option<DocumentSelector>,
1988}
1989#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1991#[serde(rename_all = "camelCase")]
1992pub struct FoldingRangeParams {
1993 #[serde(flatten)]
1994 pub work_done_progress_params_mixin: WorkDoneProgressParams,
1995 #[serde(flatten)]
1996 pub partial_result_params_mixin: PartialResultParams,
1997 #[serde(rename = "textDocument")]
1999 pub text_document: TextDocumentIdentifier,
2000}
2001#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2004#[serde(rename_all = "camelCase")]
2005pub struct FoldingRange {
2006 #[serde(rename = "startLine")]
2009 pub start_line: Uinteger,
2010 #[serde(rename = "startCharacter")]
2012 #[serde(default)]
2013 pub start_character: Option<Uinteger>,
2014 #[serde(rename = "endLine")]
2017 pub end_line: Uinteger,
2018 #[serde(rename = "endCharacter")]
2020 #[serde(default)]
2021 pub end_character: Option<Uinteger>,
2022 #[serde(default)]
2026 pub kind: Option<FoldingRangeKind>,
2027 #[serde(rename = "collapsedText")]
2033 #[serde(default)]
2034 pub collapsed_text: Option<String>,
2035}
2036#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2037#[serde(rename_all = "camelCase")]
2038pub struct FoldingRangeRegistrationOptions {
2039 #[serde(flatten)]
2040 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
2041 #[serde(flatten)]
2042 pub folding_range_options_base: FoldingRangeOptions,
2043 #[serde(flatten)]
2044 pub static_registration_options_mixin: StaticRegistrationOptions,
2045}
2046#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2047#[serde(rename_all = "camelCase")]
2048pub struct DeclarationParams {
2049 #[serde(flatten)]
2050 pub text_document_position_params_base: TextDocumentPositionParams,
2051 #[serde(flatten)]
2052 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2053 #[serde(flatten)]
2054 pub partial_result_params_mixin: PartialResultParams,
2055}
2056#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2057#[serde(rename_all = "camelCase")]
2058pub struct DeclarationRegistrationOptions {
2059 #[serde(flatten)]
2060 pub declaration_options_base: DeclarationOptions,
2061 #[serde(flatten)]
2062 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
2063 #[serde(flatten)]
2064 pub static_registration_options_mixin: StaticRegistrationOptions,
2065}
2066#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2068#[serde(rename_all = "camelCase")]
2069pub struct SelectionRangeParams {
2070 #[serde(flatten)]
2071 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2072 #[serde(flatten)]
2073 pub partial_result_params_mixin: PartialResultParams,
2074 #[serde(rename = "textDocument")]
2076 pub text_document: TextDocumentIdentifier,
2077 pub positions: Vec<Position>,
2079}
2080#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2083#[serde(rename_all = "camelCase")]
2084pub struct SelectionRange {
2085 pub range: Range,
2087 #[serde(default)]
2089 pub parent: Option<Box<SelectionRange>>,
2090}
2091#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2092#[serde(rename_all = "camelCase")]
2093pub struct SelectionRangeRegistrationOptions {
2094 #[serde(flatten)]
2095 pub selection_range_options_base: SelectionRangeOptions,
2096 #[serde(flatten)]
2097 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
2098 #[serde(flatten)]
2099 pub static_registration_options_mixin: StaticRegistrationOptions,
2100}
2101#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2102#[serde(rename_all = "camelCase")]
2103pub struct WorkDoneProgressCreateParams {
2104 pub token: ProgressToken,
2106}
2107#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2108#[serde(rename_all = "camelCase")]
2109pub struct WorkDoneProgressCancelParams {
2110 pub token: ProgressToken,
2112}
2113#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2117#[serde(rename_all = "camelCase")]
2118pub struct CallHierarchyPrepareParams {
2119 #[serde(flatten)]
2120 pub text_document_position_params_base: TextDocumentPositionParams,
2121 #[serde(flatten)]
2122 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2123}
2124#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2129#[serde(rename_all = "camelCase")]
2130pub struct CallHierarchyItem {
2131 pub name: String,
2133 pub kind: SymbolKind,
2135 #[serde(default)]
2137 pub tags: Option<Vec<SymbolTag>>,
2138 #[serde(default)]
2140 pub detail: Option<String>,
2141 pub uri: DocumentUri,
2143 pub range: Range,
2145 #[serde(rename = "selectionRange")]
2148 pub selection_range: Range,
2149 #[serde(default)]
2152 pub data: Option<LSPAny>,
2153}
2154#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2158#[serde(rename_all = "camelCase")]
2159pub struct CallHierarchyRegistrationOptions {
2160 #[serde(flatten)]
2161 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
2162 #[serde(flatten)]
2163 pub call_hierarchy_options_base: CallHierarchyOptions,
2164 #[serde(flatten)]
2165 pub static_registration_options_mixin: StaticRegistrationOptions,
2166}
2167#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2171#[serde(rename_all = "camelCase")]
2172pub struct CallHierarchyIncomingCallsParams {
2173 #[serde(flatten)]
2174 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2175 #[serde(flatten)]
2176 pub partial_result_params_mixin: PartialResultParams,
2177 pub item: CallHierarchyItem,
2178}
2179#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2183#[serde(rename_all = "camelCase")]
2184pub struct CallHierarchyIncomingCall {
2185 pub from: CallHierarchyItem,
2187 #[serde(rename = "fromRanges")]
2190 pub from_ranges: Vec<Range>,
2191}
2192#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2196#[serde(rename_all = "camelCase")]
2197pub struct CallHierarchyOutgoingCallsParams {
2198 #[serde(flatten)]
2199 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2200 #[serde(flatten)]
2201 pub partial_result_params_mixin: PartialResultParams,
2202 pub item: CallHierarchyItem,
2203}
2204#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2208#[serde(rename_all = "camelCase")]
2209pub struct CallHierarchyOutgoingCall {
2210 pub to: CallHierarchyItem,
2212 #[serde(rename = "fromRanges")]
2216 pub from_ranges: Vec<Range>,
2217}
2218#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2220#[serde(rename_all = "camelCase")]
2221pub struct SemanticTokensParams {
2222 #[serde(flatten)]
2223 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2224 #[serde(flatten)]
2225 pub partial_result_params_mixin: PartialResultParams,
2226 #[serde(rename = "textDocument")]
2228 pub text_document: TextDocumentIdentifier,
2229}
2230#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2232#[serde(rename_all = "camelCase")]
2233pub struct SemanticTokens {
2234 #[serde(rename = "resultId")]
2239 #[serde(default)]
2240 pub result_id: Option<String>,
2241 pub data: Vec<Uinteger>,
2243}
2244#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2246#[serde(rename_all = "camelCase")]
2247pub struct SemanticTokensPartialResult {
2248 pub data: Vec<Uinteger>,
2249}
2250#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2252#[serde(rename_all = "camelCase")]
2253pub struct SemanticTokensRegistrationOptions {
2254 #[serde(flatten)]
2255 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
2256 #[serde(flatten)]
2257 pub semantic_tokens_options_base: SemanticTokensOptions,
2258 #[serde(flatten)]
2259 pub static_registration_options_mixin: StaticRegistrationOptions,
2260}
2261#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2263#[serde(rename_all = "camelCase")]
2264pub struct SemanticTokensDeltaParams {
2265 #[serde(flatten)]
2266 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2267 #[serde(flatten)]
2268 pub partial_result_params_mixin: PartialResultParams,
2269 #[serde(rename = "textDocument")]
2271 pub text_document: TextDocumentIdentifier,
2272 #[serde(rename = "previousResultId")]
2275 pub previous_result_id: String,
2276}
2277#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2279#[serde(rename_all = "camelCase")]
2280pub struct SemanticTokensDelta {
2281 #[serde(rename = "resultId")]
2282 #[serde(default)]
2283 pub result_id: Option<String>,
2284 pub edits: Vec<SemanticTokensEdit>,
2286}
2287#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2289#[serde(rename_all = "camelCase")]
2290pub struct SemanticTokensDeltaPartialResult {
2291 pub edits: Vec<SemanticTokensEdit>,
2292}
2293#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2295#[serde(rename_all = "camelCase")]
2296pub struct SemanticTokensRangeParams {
2297 #[serde(flatten)]
2298 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2299 #[serde(flatten)]
2300 pub partial_result_params_mixin: PartialResultParams,
2301 #[serde(rename = "textDocument")]
2303 pub text_document: TextDocumentIdentifier,
2304 pub range: Range,
2306}
2307#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2311#[serde(rename_all = "camelCase")]
2312pub struct ShowDocumentParams {
2313 pub uri: URI,
2315 #[serde(default)]
2319 pub external: Option<bool>,
2320 #[serde(rename = "takeFocus")]
2325 #[serde(default)]
2326 pub take_focus: Option<bool>,
2327 #[serde(default)]
2332 pub selection: Option<Range>,
2333}
2334#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2338#[serde(rename_all = "camelCase")]
2339pub struct ShowDocumentResult {
2340 pub success: bool,
2342}
2343#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2344#[serde(rename_all = "camelCase")]
2345pub struct LinkedEditingRangeParams {
2346 #[serde(flatten)]
2347 pub text_document_position_params_base: TextDocumentPositionParams,
2348 #[serde(flatten)]
2349 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2350}
2351#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2355#[serde(rename_all = "camelCase")]
2356pub struct LinkedEditingRanges {
2357 pub ranges: Vec<Range>,
2360 #[serde(rename = "wordPattern")]
2364 #[serde(default)]
2365 pub word_pattern: Option<String>,
2366}
2367#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2368#[serde(rename_all = "camelCase")]
2369pub struct LinkedEditingRangeRegistrationOptions {
2370 #[serde(flatten)]
2371 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
2372 #[serde(flatten)]
2373 pub linked_editing_range_options_base: LinkedEditingRangeOptions,
2374 #[serde(flatten)]
2375 pub static_registration_options_mixin: StaticRegistrationOptions,
2376}
2377#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2382#[serde(rename_all = "camelCase")]
2383pub struct CreateFilesParams {
2384 pub files: Vec<FileCreate>,
2386}
2387#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2400#[serde(rename_all = "camelCase")]
2401pub struct WorkspaceEdit {
2402 #[serde(default)]
2404 pub changes: Option<std::collections::BTreeMap<DocumentUri, Vec<TextEdit>>>,
2405 #[serde(rename = "documentChanges")]
2416 #[serde(default)]
2417 pub document_changes: Option<
2418 Vec<CreateFileOrDeleteFileOrRenameFileOrTextDocumentEdit>,
2419 >,
2420 #[serde(rename = "changeAnnotations")]
2427 #[serde(default)]
2428 pub change_annotations: Option<
2429 std::collections::BTreeMap<ChangeAnnotationIdentifier, ChangeAnnotation>,
2430 >,
2431}
2432#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2436#[serde(rename_all = "camelCase")]
2437pub struct FileOperationRegistrationOptions {
2438 pub filters: Vec<FileOperationFilter>,
2440}
2441#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2446#[serde(rename_all = "camelCase")]
2447pub struct RenameFilesParams {
2448 pub files: Vec<FileRename>,
2451}
2452#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2457#[serde(rename_all = "camelCase")]
2458pub struct DeleteFilesParams {
2459 pub files: Vec<FileDelete>,
2461}
2462#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2463#[serde(rename_all = "camelCase")]
2464pub struct MonikerParams {
2465 #[serde(flatten)]
2466 pub text_document_position_params_base: TextDocumentPositionParams,
2467 #[serde(flatten)]
2468 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2469 #[serde(flatten)]
2470 pub partial_result_params_mixin: PartialResultParams,
2471}
2472#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2476#[serde(rename_all = "camelCase")]
2477pub struct Moniker {
2478 pub scheme: String,
2480 pub identifier: String,
2483 pub unique: UniquenessLevel,
2485 #[serde(default)]
2487 pub kind: Option<MonikerKind>,
2488}
2489#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2490#[serde(rename_all = "camelCase")]
2491pub struct MonikerRegistrationOptions {
2492 #[serde(flatten)]
2493 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
2494 #[serde(flatten)]
2495 pub moniker_options_base: MonikerOptions,
2496}
2497#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2501#[serde(rename_all = "camelCase")]
2502pub struct TypeHierarchyPrepareParams {
2503 #[serde(flatten)]
2504 pub text_document_position_params_base: TextDocumentPositionParams,
2505 #[serde(flatten)]
2506 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2507}
2508#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2510#[serde(rename_all = "camelCase")]
2511pub struct TypeHierarchyItem {
2512 pub name: String,
2514 pub kind: SymbolKind,
2516 #[serde(default)]
2518 pub tags: Option<Vec<SymbolTag>>,
2519 #[serde(default)]
2521 pub detail: Option<String>,
2522 pub uri: DocumentUri,
2524 pub range: Range,
2527 #[serde(rename = "selectionRange")]
2531 pub selection_range: Range,
2532 #[serde(default)]
2537 pub data: Option<LSPAny>,
2538}
2539#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2543#[serde(rename_all = "camelCase")]
2544pub struct TypeHierarchyRegistrationOptions {
2545 #[serde(flatten)]
2546 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
2547 #[serde(flatten)]
2548 pub type_hierarchy_options_base: TypeHierarchyOptions,
2549 #[serde(flatten)]
2550 pub static_registration_options_mixin: StaticRegistrationOptions,
2551}
2552#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2556#[serde(rename_all = "camelCase")]
2557pub struct TypeHierarchySupertypesParams {
2558 #[serde(flatten)]
2559 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2560 #[serde(flatten)]
2561 pub partial_result_params_mixin: PartialResultParams,
2562 pub item: TypeHierarchyItem,
2563}
2564#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2568#[serde(rename_all = "camelCase")]
2569pub struct TypeHierarchySubtypesParams {
2570 #[serde(flatten)]
2571 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2572 #[serde(flatten)]
2573 pub partial_result_params_mixin: PartialResultParams,
2574 pub item: TypeHierarchyItem,
2575}
2576#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2580#[serde(rename_all = "camelCase")]
2581pub struct InlineValueParams {
2582 #[serde(flatten)]
2583 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2584 #[serde(rename = "textDocument")]
2586 pub text_document: TextDocumentIdentifier,
2587 pub range: Range,
2589 #[doc = "Additional information about the context in which inline values information was\nrequested.\t */"]
2590 pub context: InlineValueContext,
2591}
2592#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2596#[serde(rename_all = "camelCase")]
2597pub struct InlineValueRegistrationOptions {
2598 #[serde(flatten)]
2599 pub inline_value_options_base: InlineValueOptions,
2600 #[serde(flatten)]
2601 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
2602 #[serde(flatten)]
2603 pub static_registration_options_mixin: StaticRegistrationOptions,
2604}
2605#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2609#[serde(rename_all = "camelCase")]
2610pub struct InlayHintParams {
2611 #[serde(flatten)]
2612 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2613 #[serde(rename = "textDocument")]
2615 pub text_document: TextDocumentIdentifier,
2616 pub range: Range,
2618}
2619#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2623#[serde(rename_all = "camelCase")]
2624pub struct InlayHint {
2625 pub position: Position,
2630 pub label: InlayHintLabelPartArrayOrString,
2635 #[serde(default)]
2638 pub kind: Option<InlayHintKind>,
2639 #[serde(rename = "textEdits")]
2645 #[serde(default)]
2646 pub text_edits: Option<Vec<TextEdit>>,
2647 #[serde(default)]
2649 pub tooltip: Option<MarkupContentOrString>,
2650 #[serde(rename = "paddingLeft")]
2656 #[serde(default)]
2657 pub padding_left: Option<bool>,
2658 #[serde(rename = "paddingRight")]
2664 #[serde(default)]
2665 pub padding_right: Option<bool>,
2666 #[serde(default)]
2669 pub data: Option<LSPAny>,
2670}
2671#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2675#[serde(rename_all = "camelCase")]
2676pub struct InlayHintRegistrationOptions {
2677 #[serde(flatten)]
2678 pub inlay_hint_options_base: InlayHintOptions,
2679 #[serde(flatten)]
2680 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
2681 #[serde(flatten)]
2682 pub static_registration_options_mixin: StaticRegistrationOptions,
2683}
2684#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2688#[serde(rename_all = "camelCase")]
2689pub struct DocumentDiagnosticParams {
2690 #[serde(flatten)]
2691 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2692 #[serde(flatten)]
2693 pub partial_result_params_mixin: PartialResultParams,
2694 #[serde(rename = "textDocument")]
2696 pub text_document: TextDocumentIdentifier,
2697 #[serde(default)]
2699 pub identifier: Option<String>,
2700 #[serde(rename = "previousResultId")]
2702 #[serde(default)]
2703 pub previous_result_id: Option<String>,
2704}
2705#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2709#[serde(rename_all = "camelCase")]
2710pub struct DocumentDiagnosticReportPartialResult {
2711 #[serde(rename = "relatedDocuments")]
2712 pub related_documents: std::collections::BTreeMap<
2713 DocumentUri,
2714 FullDocumentDiagnosticReportOrUnchangedDocumentDiagnosticReport,
2715 >,
2716}
2717#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2721#[serde(rename_all = "camelCase")]
2722pub struct DiagnosticServerCancellationData {
2723 #[serde(rename = "retriggerRequest")]
2724 pub retrigger_request: bool,
2725}
2726#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2730#[serde(rename_all = "camelCase")]
2731pub struct DiagnosticRegistrationOptions {
2732 #[serde(flatten)]
2733 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
2734 #[serde(flatten)]
2735 pub diagnostic_options_base: DiagnosticOptions,
2736 #[serde(flatten)]
2737 pub static_registration_options_mixin: StaticRegistrationOptions,
2738}
2739#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2743#[serde(rename_all = "camelCase")]
2744pub struct WorkspaceDiagnosticParams {
2745 #[serde(flatten)]
2746 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2747 #[serde(flatten)]
2748 pub partial_result_params_mixin: PartialResultParams,
2749 #[serde(default)]
2751 pub identifier: Option<String>,
2752 #[serde(rename = "previousResultIds")]
2755 pub previous_result_ids: Vec<PreviousResultId>,
2756}
2757#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2761#[serde(rename_all = "camelCase")]
2762pub struct WorkspaceDiagnosticReport {
2763 pub items: Vec<WorkspaceDocumentDiagnosticReport>,
2764}
2765#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2769#[serde(rename_all = "camelCase")]
2770pub struct WorkspaceDiagnosticReportPartialResult {
2771 pub items: Vec<WorkspaceDocumentDiagnosticReport>,
2772}
2773#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2777#[serde(rename_all = "camelCase")]
2778pub struct DidOpenNotebookDocumentParams {
2779 #[serde(rename = "notebookDocument")]
2781 pub notebook_document: NotebookDocument,
2782 #[serde(rename = "cellTextDocuments")]
2785 pub cell_text_documents: Vec<TextDocumentItem>,
2786}
2787#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2791#[serde(rename_all = "camelCase")]
2792pub struct NotebookDocumentSyncRegistrationOptions {
2793 #[serde(flatten)]
2794 pub notebook_document_sync_options_base: NotebookDocumentSyncOptions,
2795 #[serde(flatten)]
2796 pub static_registration_options_mixin: StaticRegistrationOptions,
2797}
2798#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2802#[serde(rename_all = "camelCase")]
2803pub struct DidChangeNotebookDocumentParams {
2804 #[serde(rename = "notebookDocument")]
2809 pub notebook_document: VersionedNotebookDocumentIdentifier,
2810 pub change: NotebookDocumentChangeEvent,
2824}
2825#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2829#[serde(rename_all = "camelCase")]
2830pub struct DidSaveNotebookDocumentParams {
2831 #[serde(rename = "notebookDocument")]
2833 pub notebook_document: NotebookDocumentIdentifier,
2834}
2835#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2839#[serde(rename_all = "camelCase")]
2840pub struct DidCloseNotebookDocumentParams {
2841 #[serde(rename = "notebookDocument")]
2843 pub notebook_document: NotebookDocumentIdentifier,
2844 #[serde(rename = "cellTextDocuments")]
2847 pub cell_text_documents: Vec<TextDocumentIdentifier>,
2848}
2849#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2853#[serde(rename_all = "camelCase")]
2854pub struct InlineCompletionParams {
2855 #[serde(flatten)]
2856 pub text_document_position_params_base: TextDocumentPositionParams,
2857 #[serde(flatten)]
2858 pub work_done_progress_params_mixin: WorkDoneProgressParams,
2859 pub context: InlineCompletionContext,
2862}
2863#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2867#[serde(rename_all = "camelCase")]
2868pub struct InlineCompletionList {
2869 pub items: Vec<InlineCompletionItem>,
2871}
2872#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2876#[serde(rename_all = "camelCase")]
2877pub struct InlineCompletionItem {
2878 #[serde(rename = "insertText")]
2880 pub insert_text: StringOrStringValue,
2881 #[serde(rename = "filterText")]
2883 #[serde(default)]
2884 pub filter_text: Option<String>,
2885 #[serde(default)]
2887 pub range: Option<Range>,
2888 #[serde(default)]
2890 pub command: Option<Command>,
2891}
2892#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2896#[serde(rename_all = "camelCase")]
2897pub struct InlineCompletionRegistrationOptions {
2898 #[serde(flatten)]
2899 pub inline_completion_options_base: InlineCompletionOptions,
2900 #[serde(flatten)]
2901 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
2902 #[serde(flatten)]
2903 pub static_registration_options_mixin: StaticRegistrationOptions,
2904}
2905#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2909#[serde(rename_all = "camelCase")]
2910pub struct TextDocumentContentParams {
2911 #[serde(rename = "textDocument")]
2913 pub text_document: TextDocumentIdentifier,
2914}
2915#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2919#[serde(rename_all = "camelCase")]
2920pub struct TextDocumentContentResult {
2921 pub text: String,
2926}
2927#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2931#[serde(rename_all = "camelCase")]
2932pub struct TextDocumentContentRegistrationOptions {
2933 #[serde(flatten)]
2934 pub text_document_content_options_base: TextDocumentContentOptions,
2935 #[serde(flatten)]
2936 pub static_registration_options_mixin: StaticRegistrationOptions,
2937}
2938#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2942#[serde(rename_all = "camelCase")]
2943pub struct TextDocumentContentRefreshParams {
2944 pub uri: DocumentUri,
2946}
2947#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2948#[serde(rename_all = "camelCase")]
2949pub struct RegistrationParams {
2950 pub registrations: Vec<Registration>,
2951}
2952#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2953#[serde(rename_all = "camelCase")]
2954pub struct UnregistrationParams {
2955 pub unregisterations: Vec<Unregistration>,
2956}
2957#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2958#[serde(rename_all = "camelCase")]
2959pub struct InitializeParams {
2960 #[serde(flatten)]
2961 pub initialize_params_base: _InitializeParams,
2962 #[serde(flatten)]
2963 pub workspace_folders_initialize_params_base: WorkspaceFoldersInitializeParams,
2964}
2965#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2967#[serde(rename_all = "camelCase")]
2968pub struct InitializeResult {
2969 pub capabilities: ServerCapabilities,
2971 #[serde(rename = "serverInfo")]
2975 #[serde(default)]
2976 pub server_info: Option<ServerInfo>,
2977}
2978#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2981#[serde(rename_all = "camelCase")]
2982pub struct InitializeError {
2983 pub retry: bool,
2988}
2989#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2990#[serde(rename_all = "camelCase")]
2991pub struct InitializedParams {}
2992#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2994#[serde(rename_all = "camelCase")]
2995pub struct DidChangeConfigurationParams {
2996 pub settings: LSPAny,
2998}
2999#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3000#[serde(rename_all = "camelCase")]
3001pub struct DidChangeConfigurationRegistrationOptions {
3002 #[serde(default)]
3003 pub section: Option<StringOrStringArray>,
3004}
3005#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3007#[serde(rename_all = "camelCase")]
3008pub struct ShowMessageParams {
3009 pub type_: MessageType,
3011 pub message: String,
3013}
3014#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3015#[serde(rename_all = "camelCase")]
3016pub struct ShowMessageRequestParams {
3017 pub type_: MessageType,
3019 pub message: String,
3021 #[serde(default)]
3023 pub actions: Option<Vec<MessageActionItem>>,
3024}
3025#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3026#[serde(rename_all = "camelCase")]
3027pub struct MessageActionItem {
3028 pub title: String,
3030}
3031#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3033#[serde(rename_all = "camelCase")]
3034pub struct LogMessageParams {
3035 pub type_: MessageType,
3037 pub message: String,
3039}
3040#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3042#[serde(rename_all = "camelCase")]
3043pub struct DidOpenTextDocumentParams {
3044 #[serde(rename = "textDocument")]
3046 pub text_document: TextDocumentItem,
3047}
3048#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3050#[serde(rename_all = "camelCase")]
3051pub struct DidChangeTextDocumentParams {
3052 #[serde(rename = "textDocument")]
3056 pub text_document: VersionedTextDocumentIdentifier,
3057 #[serde(rename = "contentChanges")]
3069 pub content_changes: Vec<TextDocumentContentChangeEvent>,
3070}
3071#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3073#[serde(rename_all = "camelCase")]
3074pub struct TextDocumentChangeRegistrationOptions {
3075 #[serde(flatten)]
3076 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3077 #[serde(rename = "syncKind")]
3079 pub sync_kind: TextDocumentSyncKind,
3080}
3081#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3083#[serde(rename_all = "camelCase")]
3084pub struct DidCloseTextDocumentParams {
3085 #[serde(rename = "textDocument")]
3087 pub text_document: TextDocumentIdentifier,
3088}
3089#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3091#[serde(rename_all = "camelCase")]
3092pub struct DidSaveTextDocumentParams {
3093 #[serde(rename = "textDocument")]
3095 pub text_document: TextDocumentIdentifier,
3096 #[serde(default)]
3099 pub text: Option<String>,
3100}
3101#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3103#[serde(rename_all = "camelCase")]
3104pub struct TextDocumentSaveRegistrationOptions {
3105 #[serde(flatten)]
3106 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3107 #[serde(flatten)]
3108 pub save_options_base: SaveOptions,
3109}
3110#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3112#[serde(rename_all = "camelCase")]
3113pub struct WillSaveTextDocumentParams {
3114 #[serde(rename = "textDocument")]
3116 pub text_document: TextDocumentIdentifier,
3117 pub reason: TextDocumentSaveReason,
3119}
3120#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3122#[serde(rename_all = "camelCase")]
3123pub struct TextEdit {
3124 pub range: Range,
3127 #[serde(rename = "newText")]
3130 pub new_text: String,
3131}
3132#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3134#[serde(rename_all = "camelCase")]
3135pub struct DidChangeWatchedFilesParams {
3136 pub changes: Vec<FileEvent>,
3138}
3139#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3141#[serde(rename_all = "camelCase")]
3142pub struct DidChangeWatchedFilesRegistrationOptions {
3143 pub watchers: Vec<FileSystemWatcher>,
3145}
3146#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3148#[serde(rename_all = "camelCase")]
3149pub struct PublishDiagnosticsParams {
3150 pub uri: DocumentUri,
3152 #[serde(default)]
3156 pub version: Option<Integer>,
3157 pub diagnostics: Vec<Diagnostic>,
3159}
3160#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3162#[serde(rename_all = "camelCase")]
3163pub struct CompletionParams {
3164 #[serde(flatten)]
3165 pub text_document_position_params_base: TextDocumentPositionParams,
3166 #[serde(flatten)]
3167 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3168 #[serde(flatten)]
3169 pub partial_result_params_mixin: PartialResultParams,
3170 #[serde(default)]
3173 pub context: Option<CompletionContext>,
3174}
3175#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3178#[serde(rename_all = "camelCase")]
3179pub struct CompletionItem {
3180 pub label: String,
3188 #[serde(rename = "labelDetails")]
3192 #[serde(default)]
3193 pub label_details: Option<CompletionItemLabelDetails>,
3194 #[serde(default)]
3197 pub kind: Option<CompletionItemKind>,
3198 #[serde(default)]
3202 pub tags: Option<Vec<CompletionItemTag>>,
3203 #[serde(default)]
3206 pub detail: Option<String>,
3207 #[serde(default)]
3209 pub documentation: Option<MarkupContentOrString>,
3210 #[serde(default)]
3213 pub deprecated: Option<bool>,
3214 #[serde(default)]
3220 pub preselect: Option<bool>,
3221 #[serde(rename = "sortText")]
3225 #[serde(default)]
3226 pub sort_text: Option<String>,
3227 #[serde(rename = "filterText")]
3231 #[serde(default)]
3232 pub filter_text: Option<String>,
3233 #[serde(rename = "insertText")]
3245 #[serde(default)]
3246 pub insert_text: Option<String>,
3247 #[serde(rename = "insertTextFormat")]
3254 #[serde(default)]
3255 pub insert_text_format: Option<InsertTextFormat>,
3256 #[serde(rename = "insertTextMode")]
3262 #[serde(default)]
3263 pub insert_text_mode: Option<InsertTextMode>,
3264 #[serde(rename = "textEdit")]
3285 #[serde(default)]
3286 pub text_edit: Option<InsertReplaceEditOrTextEdit>,
3287 #[serde(rename = "textEditText")]
3298 #[serde(default)]
3299 pub text_edit_text: Option<String>,
3300 #[serde(rename = "additionalTextEdits")]
3308 #[serde(default)]
3309 pub additional_text_edits: Option<Vec<TextEdit>>,
3310 #[serde(rename = "commitCharacters")]
3314 #[serde(default)]
3315 pub commit_characters: Option<Vec<String>>,
3316 #[serde(default)]
3320 pub command: Option<Command>,
3321 #[serde(default)]
3324 pub data: Option<LSPAny>,
3325}
3326#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3329#[serde(rename_all = "camelCase")]
3330pub struct CompletionList {
3331 #[serde(rename = "isIncomplete")]
3336 pub is_incomplete: bool,
3337 #[serde(rename = "itemDefaults")]
3353 #[serde(default)]
3354 pub item_defaults: Option<CompletionItemDefaults>,
3355 #[serde(rename = "applyKind")]
3373 #[serde(default)]
3374 pub apply_kind: Option<CompletionItemApplyKinds>,
3375 pub items: Vec<CompletionItem>,
3377}
3378#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3380#[serde(rename_all = "camelCase")]
3381pub struct CompletionRegistrationOptions {
3382 #[serde(flatten)]
3383 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3384 #[serde(flatten)]
3385 pub completion_options_base: CompletionOptions,
3386}
3387#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3389#[serde(rename_all = "camelCase")]
3390pub struct HoverParams {
3391 #[serde(flatten)]
3392 pub text_document_position_params_base: TextDocumentPositionParams,
3393 #[serde(flatten)]
3394 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3395}
3396#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3398#[serde(rename_all = "camelCase")]
3399pub struct Hover {
3400 pub contents: MarkedStringOrMarkedStringArrayOrMarkupContent,
3402 #[serde(default)]
3405 pub range: Option<Range>,
3406}
3407#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3409#[serde(rename_all = "camelCase")]
3410pub struct HoverRegistrationOptions {
3411 #[serde(flatten)]
3412 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3413 #[serde(flatten)]
3414 pub hover_options_base: HoverOptions,
3415}
3416#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3418#[serde(rename_all = "camelCase")]
3419pub struct SignatureHelpParams {
3420 #[serde(flatten)]
3421 pub text_document_position_params_base: TextDocumentPositionParams,
3422 #[serde(flatten)]
3423 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3424 #[serde(default)]
3429 pub context: Option<SignatureHelpContext>,
3430}
3431#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3435#[serde(rename_all = "camelCase")]
3436pub struct SignatureHelp {
3437 pub signatures: Vec<SignatureInformation>,
3439 #[serde(rename = "activeSignature")]
3449 #[serde(default)]
3450 pub active_signature: Option<Uinteger>,
3451 #[serde(rename = "activeParameter")]
3471 #[serde(default)]
3472 pub active_parameter: Option<Option<Uinteger>>,
3473}
3474#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3476#[serde(rename_all = "camelCase")]
3477pub struct SignatureHelpRegistrationOptions {
3478 #[serde(flatten)]
3479 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3480 #[serde(flatten)]
3481 pub signature_help_options_base: SignatureHelpOptions,
3482}
3483#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3485#[serde(rename_all = "camelCase")]
3486pub struct DefinitionParams {
3487 #[serde(flatten)]
3488 pub text_document_position_params_base: TextDocumentPositionParams,
3489 #[serde(flatten)]
3490 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3491 #[serde(flatten)]
3492 pub partial_result_params_mixin: PartialResultParams,
3493}
3494#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3496#[serde(rename_all = "camelCase")]
3497pub struct DefinitionRegistrationOptions {
3498 #[serde(flatten)]
3499 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3500 #[serde(flatten)]
3501 pub definition_options_base: DefinitionOptions,
3502}
3503#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3505#[serde(rename_all = "camelCase")]
3506pub struct ReferenceParams {
3507 #[serde(flatten)]
3508 pub text_document_position_params_base: TextDocumentPositionParams,
3509 #[serde(flatten)]
3510 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3511 #[serde(flatten)]
3512 pub partial_result_params_mixin: PartialResultParams,
3513 pub context: ReferenceContext,
3514}
3515#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3517#[serde(rename_all = "camelCase")]
3518pub struct ReferenceRegistrationOptions {
3519 #[serde(flatten)]
3520 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3521 #[serde(flatten)]
3522 pub reference_options_base: ReferenceOptions,
3523}
3524#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3526#[serde(rename_all = "camelCase")]
3527pub struct DocumentHighlightParams {
3528 #[serde(flatten)]
3529 pub text_document_position_params_base: TextDocumentPositionParams,
3530 #[serde(flatten)]
3531 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3532 #[serde(flatten)]
3533 pub partial_result_params_mixin: PartialResultParams,
3534}
3535#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3539#[serde(rename_all = "camelCase")]
3540pub struct DocumentHighlight {
3541 pub range: Range,
3543 #[serde(default)]
3545 pub kind: Option<DocumentHighlightKind>,
3546}
3547#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3549#[serde(rename_all = "camelCase")]
3550pub struct DocumentHighlightRegistrationOptions {
3551 #[serde(flatten)]
3552 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3553 #[serde(flatten)]
3554 pub document_highlight_options_base: DocumentHighlightOptions,
3555}
3556#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3558#[serde(rename_all = "camelCase")]
3559pub struct DocumentSymbolParams {
3560 #[serde(flatten)]
3561 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3562 #[serde(flatten)]
3563 pub partial_result_params_mixin: PartialResultParams,
3564 #[serde(rename = "textDocument")]
3566 pub text_document: TextDocumentIdentifier,
3567}
3568#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3571#[serde(rename_all = "camelCase")]
3572pub struct SymbolInformation {
3573 #[serde(flatten)]
3574 pub base_symbol_information_base: BaseSymbolInformation,
3575 #[serde(default)]
3579 pub deprecated: Option<bool>,
3580 pub location: Location,
3590}
3591#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3596#[serde(rename_all = "camelCase")]
3597pub struct DocumentSymbol {
3598 pub name: String,
3601 #[serde(default)]
3603 pub detail: Option<String>,
3604 pub kind: SymbolKind,
3606 #[serde(default)]
3610 pub tags: Option<Vec<SymbolTag>>,
3611 #[serde(default)]
3615 pub deprecated: Option<bool>,
3616 pub range: Range,
3620 #[serde(rename = "selectionRange")]
3623 pub selection_range: Range,
3624 #[serde(default)]
3626 pub children: Option<Vec<DocumentSymbol>>,
3627}
3628#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3630#[serde(rename_all = "camelCase")]
3631pub struct DocumentSymbolRegistrationOptions {
3632 #[serde(flatten)]
3633 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3634 #[serde(flatten)]
3635 pub document_symbol_options_base: DocumentSymbolOptions,
3636}
3637#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3639#[serde(rename_all = "camelCase")]
3640pub struct CodeActionParams {
3641 #[serde(flatten)]
3642 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3643 #[serde(flatten)]
3644 pub partial_result_params_mixin: PartialResultParams,
3645 #[serde(rename = "textDocument")]
3647 pub text_document: TextDocumentIdentifier,
3648 pub range: Range,
3650 pub context: CodeActionContext,
3652}
3653#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3658#[serde(rename_all = "camelCase")]
3659pub struct Command {
3660 pub title: String,
3662 #[serde(default)]
3666 pub tooltip: Option<String>,
3667 pub command: String,
3669 #[serde(default)]
3672 pub arguments: Option<Vec<LSPAny>>,
3673}
3674#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3679#[serde(rename_all = "camelCase")]
3680pub struct CodeAction {
3681 pub title: String,
3683 #[serde(default)]
3687 pub kind: Option<CodeActionKind>,
3688 #[serde(default)]
3690 pub diagnostics: Option<Vec<Diagnostic>>,
3691 #[serde(rename = "isPreferred")]
3699 #[serde(default)]
3700 pub is_preferred: Option<bool>,
3701 #[serde(default)]
3717 pub disabled: Option<CodeActionDisabled>,
3718 #[serde(default)]
3720 pub edit: Option<WorkspaceEdit>,
3721 #[serde(default)]
3725 pub command: Option<Command>,
3726 #[serde(default)]
3731 pub data: Option<LSPAny>,
3732 #[serde(default)]
3736 pub tags: Option<Vec<CodeActionTag>>,
3737}
3738#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3740#[serde(rename_all = "camelCase")]
3741pub struct CodeActionRegistrationOptions {
3742 #[serde(flatten)]
3743 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3744 #[serde(flatten)]
3745 pub code_action_options_base: CodeActionOptions,
3746}
3747#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3749#[serde(rename_all = "camelCase")]
3750pub struct WorkspaceSymbolParams {
3751 #[serde(flatten)]
3752 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3753 #[serde(flatten)]
3754 pub partial_result_params_mixin: PartialResultParams,
3755 pub query: String,
3764}
3765#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3771#[serde(rename_all = "camelCase")]
3772pub struct WorkspaceSymbol {
3773 #[serde(flatten)]
3774 pub base_symbol_information_base: BaseSymbolInformation,
3775 pub location: LocationOrLocationUriOnly,
3781 #[serde(default)]
3784 pub data: Option<LSPAny>,
3785}
3786#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3788#[serde(rename_all = "camelCase")]
3789pub struct WorkspaceSymbolRegistrationOptions {
3790 #[serde(flatten)]
3791 pub workspace_symbol_options_base: WorkspaceSymbolOptions,
3792}
3793#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3795#[serde(rename_all = "camelCase")]
3796pub struct CodeLensParams {
3797 #[serde(flatten)]
3798 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3799 #[serde(flatten)]
3800 pub partial_result_params_mixin: PartialResultParams,
3801 #[serde(rename = "textDocument")]
3803 pub text_document: TextDocumentIdentifier,
3804}
3805#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3811#[serde(rename_all = "camelCase")]
3812pub struct CodeLens {
3813 pub range: Range,
3815 #[serde(default)]
3817 pub command: Option<Command>,
3818 #[serde(default)]
3821 pub data: Option<LSPAny>,
3822}
3823#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3825#[serde(rename_all = "camelCase")]
3826pub struct CodeLensRegistrationOptions {
3827 #[serde(flatten)]
3828 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3829 #[serde(flatten)]
3830 pub code_lens_options_base: CodeLensOptions,
3831}
3832#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3834#[serde(rename_all = "camelCase")]
3835pub struct DocumentLinkParams {
3836 #[serde(flatten)]
3837 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3838 #[serde(flatten)]
3839 pub partial_result_params_mixin: PartialResultParams,
3840 #[serde(rename = "textDocument")]
3842 pub text_document: TextDocumentIdentifier,
3843}
3844#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3847#[serde(rename_all = "camelCase")]
3848pub struct DocumentLink {
3849 pub range: Range,
3851 #[serde(default)]
3853 pub target: Option<URI>,
3854 #[serde(default)]
3862 pub tooltip: Option<String>,
3863 #[serde(default)]
3866 pub data: Option<LSPAny>,
3867}
3868#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3870#[serde(rename_all = "camelCase")]
3871pub struct DocumentLinkRegistrationOptions {
3872 #[serde(flatten)]
3873 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3874 #[serde(flatten)]
3875 pub document_link_options_base: DocumentLinkOptions,
3876}
3877#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3879#[serde(rename_all = "camelCase")]
3880pub struct DocumentFormattingParams {
3881 #[serde(flatten)]
3882 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3883 #[serde(rename = "textDocument")]
3885 pub text_document: TextDocumentIdentifier,
3886 pub options: FormattingOptions,
3888}
3889#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3891#[serde(rename_all = "camelCase")]
3892pub struct DocumentFormattingRegistrationOptions {
3893 #[serde(flatten)]
3894 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3895 #[serde(flatten)]
3896 pub document_formatting_options_base: DocumentFormattingOptions,
3897}
3898#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3900#[serde(rename_all = "camelCase")]
3901pub struct DocumentRangeFormattingParams {
3902 #[serde(flatten)]
3903 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3904 #[serde(rename = "textDocument")]
3906 pub text_document: TextDocumentIdentifier,
3907 pub range: Range,
3909 pub options: FormattingOptions,
3911}
3912#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3914#[serde(rename_all = "camelCase")]
3915pub struct DocumentRangeFormattingRegistrationOptions {
3916 #[serde(flatten)]
3917 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3918 #[serde(flatten)]
3919 pub document_range_formatting_options_base: DocumentRangeFormattingOptions,
3920}
3921#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3925#[serde(rename_all = "camelCase")]
3926pub struct DocumentRangesFormattingParams {
3927 #[serde(flatten)]
3928 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3929 #[serde(rename = "textDocument")]
3931 pub text_document: TextDocumentIdentifier,
3932 pub ranges: Vec<Range>,
3934 pub options: FormattingOptions,
3936}
3937#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3939#[serde(rename_all = "camelCase")]
3940pub struct DocumentOnTypeFormattingParams {
3941 #[serde(rename = "textDocument")]
3943 pub text_document: TextDocumentIdentifier,
3944 pub position: Position,
3948 pub ch: String,
3953 pub options: FormattingOptions,
3955}
3956#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3958#[serde(rename_all = "camelCase")]
3959pub struct DocumentOnTypeFormattingRegistrationOptions {
3960 #[serde(flatten)]
3961 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3962 #[serde(flatten)]
3963 pub document_on_type_formatting_options_base: DocumentOnTypeFormattingOptions,
3964}
3965#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3967#[serde(rename_all = "camelCase")]
3968pub struct RenameParams {
3969 #[serde(flatten)]
3970 pub text_document_position_params_base: TextDocumentPositionParams,
3971 #[serde(flatten)]
3972 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3973 #[serde(rename = "newName")]
3977 pub new_name: String,
3978}
3979#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3981#[serde(rename_all = "camelCase")]
3982pub struct RenameRegistrationOptions {
3983 #[serde(flatten)]
3984 pub text_document_registration_options_base: TextDocumentRegistrationOptions,
3985 #[serde(flatten)]
3986 pub rename_options_base: RenameOptions,
3987}
3988#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3989#[serde(rename_all = "camelCase")]
3990pub struct PrepareRenameParams {
3991 #[serde(flatten)]
3992 pub text_document_position_params_base: TextDocumentPositionParams,
3993 #[serde(flatten)]
3994 pub work_done_progress_params_mixin: WorkDoneProgressParams,
3995}
3996#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
3998#[serde(rename_all = "camelCase")]
3999pub struct ExecuteCommandParams {
4000 #[serde(flatten)]
4001 pub work_done_progress_params_mixin: WorkDoneProgressParams,
4002 pub command: String,
4004 #[serde(default)]
4006 pub arguments: Option<Vec<LSPAny>>,
4007}
4008#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4010#[serde(rename_all = "camelCase")]
4011pub struct ExecuteCommandRegistrationOptions {
4012 #[serde(flatten)]
4013 pub execute_command_options_base: ExecuteCommandOptions,
4014}
4015#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4017#[serde(rename_all = "camelCase")]
4018pub struct ApplyWorkspaceEditParams {
4019 #[serde(default)]
4023 pub label: Option<String>,
4024 pub edit: WorkspaceEdit,
4026 #[serde(default)]
4030 pub metadata: Option<WorkspaceEditMetadata>,
4031}
4032#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4036#[serde(rename_all = "camelCase")]
4037pub struct ApplyWorkspaceEditResult {
4038 pub applied: bool,
4040 #[serde(rename = "failureReason")]
4044 #[serde(default)]
4045 pub failure_reason: Option<String>,
4046 #[serde(rename = "failedChange")]
4050 #[serde(default)]
4051 pub failed_change: Option<Uinteger>,
4052}
4053#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4054#[serde(rename_all = "camelCase")]
4055pub struct WorkDoneProgressBegin {
4056 pub kind: String,
4057 pub title: String,
4062 #[serde(default)]
4066 pub cancellable: Option<bool>,
4067 #[serde(default)]
4073 pub message: Option<String>,
4074 #[serde(default)]
4081 pub percentage: Option<Uinteger>,
4082}
4083#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4084#[serde(rename_all = "camelCase")]
4085pub struct WorkDoneProgressReport {
4086 pub kind: String,
4087 #[serde(default)]
4092 pub cancellable: Option<bool>,
4093 #[serde(default)]
4099 pub message: Option<String>,
4100 #[serde(default)]
4107 pub percentage: Option<Uinteger>,
4108}
4109#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4110#[serde(rename_all = "camelCase")]
4111pub struct WorkDoneProgressEnd {
4112 pub kind: String,
4113 #[serde(default)]
4116 pub message: Option<String>,
4117}
4118#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4119#[serde(rename_all = "camelCase")]
4120pub struct SetTraceParams {
4121 pub value: TraceValue,
4122}
4123#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4124#[serde(rename_all = "camelCase")]
4125pub struct LogTraceParams {
4126 pub message: String,
4127 #[serde(default)]
4128 pub verbose: Option<String>,
4129}
4130#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4131#[serde(rename_all = "camelCase")]
4132pub struct CancelParams {
4133 pub id: IntegerOrString,
4135}
4136#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4137#[serde(rename_all = "camelCase")]
4138pub struct ProgressParams {
4139 pub token: ProgressToken,
4141 pub value: LSPAny,
4143}
4144#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4147#[serde(rename_all = "camelCase")]
4148pub struct TextDocumentPositionParams {
4149 #[serde(rename = "textDocument")]
4151 pub text_document: TextDocumentIdentifier,
4152 pub position: Position,
4154}
4155#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4156#[serde(rename_all = "camelCase")]
4157pub struct WorkDoneProgressParams {
4158 #[serde(rename = "workDoneToken")]
4160 #[serde(default)]
4161 pub work_done_token: Option<ProgressToken>,
4162}
4163#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4164#[serde(rename_all = "camelCase")]
4165pub struct PartialResultParams {
4166 #[serde(rename = "partialResultToken")]
4169 #[serde(default)]
4170 pub partial_result_token: Option<ProgressToken>,
4171}
4172#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4175#[serde(rename_all = "camelCase")]
4176pub struct LocationLink {
4177 #[serde(rename = "originSelectionRange")]
4182 #[serde(default)]
4183 pub origin_selection_range: Option<Range>,
4184 #[serde(rename = "targetUri")]
4186 pub target_uri: DocumentUri,
4187 #[serde(rename = "targetRange")]
4191 pub target_range: Range,
4192 #[serde(rename = "targetSelectionRange")]
4195 pub target_selection_range: Range,
4196}
4197#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4209#[serde(rename_all = "camelCase")]
4210pub struct Range {
4211 pub start: Position,
4213 pub end: Position,
4215}
4216#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4217#[serde(rename_all = "camelCase")]
4218pub struct ImplementationOptions {
4219 #[serde(flatten)]
4220 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4221}
4222#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4225#[serde(rename_all = "camelCase")]
4226pub struct StaticRegistrationOptions {
4227 #[serde(default)]
4230 pub id: Option<String>,
4231}
4232#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4233#[serde(rename_all = "camelCase")]
4234pub struct TypeDefinitionOptions {
4235 #[serde(flatten)]
4236 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4237}
4238#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4240#[serde(rename_all = "camelCase")]
4241pub struct WorkspaceFoldersChangeEvent {
4242 pub added: Vec<WorkspaceFolder>,
4244 pub removed: Vec<WorkspaceFolder>,
4246}
4247#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4248#[serde(rename_all = "camelCase")]
4249pub struct ConfigurationItem {
4250 #[serde(rename = "scopeUri")]
4252 #[serde(default)]
4253 pub scope_uri: Option<URI>,
4254 #[serde(default)]
4256 pub section: Option<String>,
4257}
4258#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4260#[serde(rename_all = "camelCase")]
4261pub struct TextDocumentIdentifier {
4262 pub uri: DocumentUri,
4264}
4265#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4267#[serde(rename_all = "camelCase")]
4268pub struct Color {
4269 pub red: Decimal,
4271 pub green: Decimal,
4273 pub blue: Decimal,
4275 pub alpha: Decimal,
4277}
4278#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4279#[serde(rename_all = "camelCase")]
4280pub struct DocumentColorOptions {
4281 #[serde(flatten)]
4282 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4283}
4284#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4285#[serde(rename_all = "camelCase")]
4286pub struct FoldingRangeOptions {
4287 #[serde(flatten)]
4288 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4289}
4290#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4291#[serde(rename_all = "camelCase")]
4292pub struct DeclarationOptions {
4293 #[serde(flatten)]
4294 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4295}
4296#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4324#[serde(rename_all = "camelCase")]
4325pub struct Position {
4326 pub line: Uinteger,
4328 pub character: Uinteger,
4333}
4334#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4335#[serde(rename_all = "camelCase")]
4336pub struct SelectionRangeOptions {
4337 #[serde(flatten)]
4338 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4339}
4340#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4344#[serde(rename_all = "camelCase")]
4345pub struct CallHierarchyOptions {
4346 #[serde(flatten)]
4347 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4348}
4349#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4351#[serde(rename_all = "camelCase")]
4352pub struct SemanticTokensOptions {
4353 #[serde(flatten)]
4354 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4355 pub legend: SemanticTokensLegend,
4357 #[serde(default)]
4360 pub range: Option<BooleanOrLiteral57f9bf6390bb37d9>,
4361 #[serde(default)]
4363 pub full: Option<BooleanOrSemanticTokensFullDelta>,
4364}
4365#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4367#[serde(rename_all = "camelCase")]
4368pub struct SemanticTokensEdit {
4369 pub start: Uinteger,
4371 #[serde(rename = "deleteCount")]
4373 pub delete_count: Uinteger,
4374 #[serde(default)]
4376 pub data: Option<Vec<Uinteger>>,
4377}
4378#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4379#[serde(rename_all = "camelCase")]
4380pub struct LinkedEditingRangeOptions {
4381 #[serde(flatten)]
4382 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4383}
4384#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4388#[serde(rename_all = "camelCase")]
4389pub struct FileCreate {
4390 pub uri: String,
4392}
4393#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4398#[serde(rename_all = "camelCase")]
4399pub struct TextDocumentEdit {
4400 #[serde(rename = "textDocument")]
4402 pub text_document: OptionalVersionedTextDocumentIdentifier,
4403 pub edits: Vec<AnnotatedTextEditOrSnippetTextEditOrTextEdit>,
4411}
4412#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4414#[serde(rename_all = "camelCase")]
4415pub struct CreateFile {
4416 #[serde(flatten)]
4417 pub resource_operation_base: ResourceOperation,
4418 pub kind: String,
4420 pub uri: DocumentUri,
4422 #[serde(default)]
4424 pub options: Option<CreateFileOptions>,
4425}
4426#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4428#[serde(rename_all = "camelCase")]
4429pub struct RenameFile {
4430 #[serde(flatten)]
4431 pub resource_operation_base: ResourceOperation,
4432 pub kind: String,
4434 #[serde(rename = "oldUri")]
4436 pub old_uri: DocumentUri,
4437 #[serde(rename = "newUri")]
4439 pub new_uri: DocumentUri,
4440 #[serde(default)]
4442 pub options: Option<RenameFileOptions>,
4443}
4444#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4446#[serde(rename_all = "camelCase")]
4447pub struct DeleteFile {
4448 #[serde(flatten)]
4449 pub resource_operation_base: ResourceOperation,
4450 pub kind: String,
4452 pub uri: DocumentUri,
4454 #[serde(default)]
4456 pub options: Option<DeleteFileOptions>,
4457}
4458#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4462#[serde(rename_all = "camelCase")]
4463pub struct ChangeAnnotation {
4464 pub label: String,
4467 #[serde(rename = "needsConfirmation")]
4470 #[serde(default)]
4471 pub needs_confirmation: Option<bool>,
4472 #[serde(default)]
4475 pub description: Option<String>,
4476}
4477#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4482#[serde(rename_all = "camelCase")]
4483pub struct FileOperationFilter {
4484 #[serde(default)]
4486 pub scheme: Option<String>,
4487 pub pattern: FileOperationPattern,
4489}
4490#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4494#[serde(rename_all = "camelCase")]
4495pub struct FileRename {
4496 #[serde(rename = "oldUri")]
4498 pub old_uri: String,
4499 #[serde(rename = "newUri")]
4501 pub new_uri: String,
4502}
4503#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4507#[serde(rename_all = "camelCase")]
4508pub struct FileDelete {
4509 pub uri: String,
4511}
4512#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4513#[serde(rename_all = "camelCase")]
4514pub struct MonikerOptions {
4515 #[serde(flatten)]
4516 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4517}
4518#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4522#[serde(rename_all = "camelCase")]
4523pub struct TypeHierarchyOptions {
4524 #[serde(flatten)]
4525 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4526}
4527#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4529#[serde(rename_all = "camelCase")]
4530pub struct InlineValueContext {
4531 #[serde(rename = "frameId")]
4533 pub frame_id: Integer,
4534 #[serde(rename = "stoppedLocation")]
4537 pub stopped_location: Range,
4538}
4539#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4543#[serde(rename_all = "camelCase")]
4544pub struct InlineValueText {
4545 pub range: Range,
4547 pub text: String,
4549}
4550#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4560#[serde(rename_all = "camelCase")]
4561pub struct InlineValueVariableLookup {
4562 pub range: Range,
4567 #[serde(rename = "variableName")]
4569 #[serde(default)]
4570 pub variable_name: Option<String>,
4571 #[serde(rename = "caseSensitiveLookup")]
4573 pub case_sensitive_lookup: bool,
4574}
4575#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4585#[serde(rename_all = "camelCase")]
4586pub struct InlineValueEvaluatableExpression {
4587 pub range: Range,
4592 #[serde(default)]
4594 pub expression: Option<String>,
4595}
4596#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4600#[serde(rename_all = "camelCase")]
4601pub struct InlineValueOptions {
4602 #[serde(flatten)]
4603 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4604}
4605#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4610#[serde(rename_all = "camelCase")]
4611pub struct InlayHintLabelPart {
4612 pub value: String,
4614 #[serde(default)]
4618 pub tooltip: Option<MarkupContentOrString>,
4619 #[serde(default)]
4631 pub location: Option<Location>,
4632 #[serde(default)]
4637 pub command: Option<Command>,
4638}
4639#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4662#[serde(rename_all = "camelCase")]
4663pub struct MarkupContent {
4664 pub kind: MarkupKind,
4666 pub value: String,
4668}
4669#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4673#[serde(rename_all = "camelCase")]
4674pub struct InlayHintOptions {
4675 #[serde(flatten)]
4676 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4677 #[serde(rename = "resolveProvider")]
4680 #[serde(default)]
4681 pub resolve_provider: Option<bool>,
4682}
4683#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4687#[serde(rename_all = "camelCase")]
4688pub struct RelatedFullDocumentDiagnosticReport {
4689 #[serde(flatten)]
4690 pub full_document_diagnostic_report_base: FullDocumentDiagnosticReport,
4691 #[serde(rename = "relatedDocuments")]
4699 #[serde(default)]
4700 pub related_documents: Option<
4701 std::collections::BTreeMap<
4702 DocumentUri,
4703 FullDocumentDiagnosticReportOrUnchangedDocumentDiagnosticReport,
4704 >,
4705 >,
4706}
4707#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4711#[serde(rename_all = "camelCase")]
4712pub struct RelatedUnchangedDocumentDiagnosticReport {
4713 #[serde(flatten)]
4714 pub unchanged_document_diagnostic_report_base: UnchangedDocumentDiagnosticReport,
4715 #[serde(rename = "relatedDocuments")]
4723 #[serde(default)]
4724 pub related_documents: Option<
4725 std::collections::BTreeMap<
4726 DocumentUri,
4727 FullDocumentDiagnosticReportOrUnchangedDocumentDiagnosticReport,
4728 >,
4729 >,
4730}
4731#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4735#[serde(rename_all = "camelCase")]
4736pub struct FullDocumentDiagnosticReport {
4737 pub kind: String,
4739 #[serde(rename = "resultId")]
4743 #[serde(default)]
4744 pub result_id: Option<String>,
4745 pub items: Vec<Diagnostic>,
4747}
4748#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4753#[serde(rename_all = "camelCase")]
4754pub struct UnchangedDocumentDiagnosticReport {
4755 pub kind: String,
4760 #[serde(rename = "resultId")]
4763 pub result_id: String,
4764}
4765#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4769#[serde(rename_all = "camelCase")]
4770pub struct DiagnosticOptions {
4771 #[serde(flatten)]
4772 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4773 #[serde(default)]
4776 pub identifier: Option<String>,
4777 #[serde(rename = "interFileDependencies")]
4782 pub inter_file_dependencies: bool,
4783 #[serde(rename = "workspaceDiagnostics")]
4785 pub workspace_diagnostics: bool,
4786}
4787#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4791#[serde(rename_all = "camelCase")]
4792pub struct PreviousResultId {
4793 pub uri: DocumentUri,
4796 pub value: String,
4798}
4799#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4803#[serde(rename_all = "camelCase")]
4804pub struct NotebookDocument {
4805 pub uri: URI,
4807 #[serde(rename = "notebookType")]
4809 pub notebook_type: String,
4810 pub version: Integer,
4813 #[serde(default)]
4818 pub metadata: Option<LSPObject>,
4819 pub cells: Vec<NotebookCell>,
4821}
4822#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4825#[serde(rename_all = "camelCase")]
4826pub struct TextDocumentItem {
4827 pub uri: DocumentUri,
4829 #[serde(rename = "languageId")]
4831 pub language_id: LanguageKind,
4832 pub version: Integer,
4835 pub text: String,
4837}
4838#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4852#[serde(rename_all = "camelCase")]
4853pub struct NotebookDocumentSyncOptions {
4854 #[serde(rename = "notebookSelector")]
4856 pub notebook_selector: Vec<
4857 NotebookDocumentFilterWithCellsOrNotebookDocumentFilterWithNotebook,
4858 >,
4859 #[serde(default)]
4862 pub save: Option<bool>,
4863}
4864#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4868#[serde(rename_all = "camelCase")]
4869pub struct VersionedNotebookDocumentIdentifier {
4870 pub version: Integer,
4872 pub uri: URI,
4874}
4875#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4879#[serde(rename_all = "camelCase")]
4880pub struct NotebookDocumentChangeEvent {
4881 #[serde(default)]
4885 pub metadata: Option<LSPObject>,
4886 #[serde(default)]
4888 pub cells: Option<NotebookDocumentCellChanges>,
4889}
4890#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4894#[serde(rename_all = "camelCase")]
4895pub struct NotebookDocumentIdentifier {
4896 pub uri: URI,
4898}
4899#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4903#[serde(rename_all = "camelCase")]
4904pub struct InlineCompletionContext {
4905 #[serde(rename = "triggerKind")]
4907 pub trigger_kind: InlineCompletionTriggerKind,
4908 #[serde(rename = "selectedCompletionInfo")]
4910 #[serde(default)]
4911 pub selected_completion_info: Option<SelectedCompletionInfo>,
4912}
4913#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4923#[serde(rename_all = "camelCase")]
4924pub struct StringValue {
4925 pub kind: String,
4927 pub value: String,
4929}
4930#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4934#[serde(rename_all = "camelCase")]
4935pub struct InlineCompletionOptions {
4936 #[serde(flatten)]
4937 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
4938}
4939#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4943#[serde(rename_all = "camelCase")]
4944pub struct TextDocumentContentOptions {
4945 pub schemes: Vec<String>,
4947}
4948#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4950#[serde(rename_all = "camelCase")]
4951pub struct Registration {
4952 pub id: String,
4955 pub method: String,
4957 #[serde(rename = "registerOptions")]
4959 #[serde(default)]
4960 pub register_options: Option<LSPAny>,
4961}
4962#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4964#[serde(rename_all = "camelCase")]
4965pub struct Unregistration {
4966 pub id: String,
4969 pub method: String,
4971}
4972#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4974#[serde(rename_all = "camelCase")]
4975pub struct _InitializeParams {
4976 #[serde(flatten)]
4977 pub work_done_progress_params_mixin: WorkDoneProgressParams,
4978 #[serde(rename = "processId")]
4984 pub process_id: Option<Integer>,
4985 #[serde(rename = "clientInfo")]
4989 #[serde(default)]
4990 pub client_info: Option<ClientInfo>,
4991 #[serde(default)]
5000 pub locale: Option<String>,
5001 #[serde(rename = "rootPath")]
5006 #[serde(default)]
5007 pub root_path: Option<Option<String>>,
5008 #[serde(rename = "rootUri")]
5014 pub root_uri: Option<DocumentUri>,
5015 pub capabilities: ClientCapabilities,
5017 #[serde(rename = "initializationOptions")]
5019 #[serde(default)]
5020 pub initialization_options: Option<LSPAny>,
5021 #[serde(default)]
5023 pub trace: Option<TraceValue>,
5024}
5025#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5026#[serde(rename_all = "camelCase")]
5027pub struct WorkspaceFoldersInitializeParams {
5028 #[serde(rename = "workspaceFolders")]
5036 #[serde(default)]
5037 pub workspace_folders: Option<Option<Vec<WorkspaceFolder>>>,
5038}
5039#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5042#[serde(rename_all = "camelCase")]
5043pub struct ServerCapabilities {
5044 #[serde(rename = "positionEncoding")]
5054 #[serde(default)]
5055 pub position_encoding: Option<PositionEncodingKind>,
5056 #[serde(rename = "textDocumentSync")]
5060 #[serde(default)]
5061 pub text_document_sync: Option<TextDocumentSyncKindOrTextDocumentSyncOptions>,
5062 #[serde(rename = "notebookDocumentSync")]
5066 #[serde(default)]
5067 pub notebook_document_sync: Option<
5068 NotebookDocumentSyncOptionsOrNotebookDocumentSyncRegistrationOptions,
5069 >,
5070 #[serde(rename = "completionProvider")]
5072 #[serde(default)]
5073 pub completion_provider: Option<CompletionOptions>,
5074 #[serde(rename = "hoverProvider")]
5076 #[serde(default)]
5077 pub hover_provider: Option<BooleanOrHoverOptions>,
5078 #[serde(rename = "signatureHelpProvider")]
5080 #[serde(default)]
5081 pub signature_help_provider: Option<SignatureHelpOptions>,
5082 #[serde(rename = "declarationProvider")]
5084 #[serde(default)]
5085 pub declaration_provider: Option<
5086 BooleanOrDeclarationOptionsOrDeclarationRegistrationOptions,
5087 >,
5088 #[serde(rename = "definitionProvider")]
5090 #[serde(default)]
5091 pub definition_provider: Option<BooleanOrDefinitionOptions>,
5092 #[serde(rename = "typeDefinitionProvider")]
5094 #[serde(default)]
5095 pub type_definition_provider: Option<
5096 BooleanOrTypeDefinitionOptionsOrTypeDefinitionRegistrationOptions,
5097 >,
5098 #[serde(rename = "implementationProvider")]
5100 #[serde(default)]
5101 pub implementation_provider: Option<
5102 BooleanOrImplementationOptionsOrImplementationRegistrationOptions,
5103 >,
5104 #[serde(rename = "referencesProvider")]
5106 #[serde(default)]
5107 pub references_provider: Option<BooleanOrReferenceOptions>,
5108 #[serde(rename = "documentHighlightProvider")]
5110 #[serde(default)]
5111 pub document_highlight_provider: Option<BooleanOrDocumentHighlightOptions>,
5112 #[serde(rename = "documentSymbolProvider")]
5114 #[serde(default)]
5115 pub document_symbol_provider: Option<BooleanOrDocumentSymbolOptions>,
5116 #[serde(rename = "codeActionProvider")]
5120 #[serde(default)]
5121 pub code_action_provider: Option<BooleanOrCodeActionOptions>,
5122 #[serde(rename = "codeLensProvider")]
5124 #[serde(default)]
5125 pub code_lens_provider: Option<CodeLensOptions>,
5126 #[serde(rename = "documentLinkProvider")]
5128 #[serde(default)]
5129 pub document_link_provider: Option<DocumentLinkOptions>,
5130 #[serde(rename = "colorProvider")]
5132 #[serde(default)]
5133 pub color_provider: Option<
5134 BooleanOrDocumentColorOptionsOrDocumentColorRegistrationOptions,
5135 >,
5136 #[serde(rename = "workspaceSymbolProvider")]
5138 #[serde(default)]
5139 pub workspace_symbol_provider: Option<BooleanOrWorkspaceSymbolOptions>,
5140 #[serde(rename = "documentFormattingProvider")]
5142 #[serde(default)]
5143 pub document_formatting_provider: Option<BooleanOrDocumentFormattingOptions>,
5144 #[serde(rename = "documentRangeFormattingProvider")]
5146 #[serde(default)]
5147 pub document_range_formatting_provider: Option<
5148 BooleanOrDocumentRangeFormattingOptions,
5149 >,
5150 #[serde(rename = "documentOnTypeFormattingProvider")]
5152 #[serde(default)]
5153 pub document_on_type_formatting_provider: Option<DocumentOnTypeFormattingOptions>,
5154 #[serde(rename = "renameProvider")]
5158 #[serde(default)]
5159 pub rename_provider: Option<BooleanOrRenameOptions>,
5160 #[serde(rename = "foldingRangeProvider")]
5162 #[serde(default)]
5163 pub folding_range_provider: Option<
5164 BooleanOrFoldingRangeOptionsOrFoldingRangeRegistrationOptions,
5165 >,
5166 #[serde(rename = "selectionRangeProvider")]
5168 #[serde(default)]
5169 pub selection_range_provider: Option<
5170 BooleanOrSelectionRangeOptionsOrSelectionRangeRegistrationOptions,
5171 >,
5172 #[serde(rename = "executeCommandProvider")]
5174 #[serde(default)]
5175 pub execute_command_provider: Option<ExecuteCommandOptions>,
5176 #[serde(rename = "callHierarchyProvider")]
5180 #[serde(default)]
5181 pub call_hierarchy_provider: Option<
5182 BooleanOrCallHierarchyOptionsOrCallHierarchyRegistrationOptions,
5183 >,
5184 #[serde(rename = "linkedEditingRangeProvider")]
5188 #[serde(default)]
5189 pub linked_editing_range_provider: Option<
5190 BooleanOrLinkedEditingRangeOptionsOrLinkedEditingRangeRegistrationOptions,
5191 >,
5192 #[serde(rename = "semanticTokensProvider")]
5196 #[serde(default)]
5197 pub semantic_tokens_provider: Option<
5198 SemanticTokensOptionsOrSemanticTokensRegistrationOptions,
5199 >,
5200 #[serde(rename = "monikerProvider")]
5204 #[serde(default)]
5205 pub moniker_provider: Option<BooleanOrMonikerOptionsOrMonikerRegistrationOptions>,
5206 #[serde(rename = "typeHierarchyProvider")]
5210 #[serde(default)]
5211 pub type_hierarchy_provider: Option<
5212 BooleanOrTypeHierarchyOptionsOrTypeHierarchyRegistrationOptions,
5213 >,
5214 #[serde(rename = "inlineValueProvider")]
5218 #[serde(default)]
5219 pub inline_value_provider: Option<
5220 BooleanOrInlineValueOptionsOrInlineValueRegistrationOptions,
5221 >,
5222 #[serde(rename = "inlayHintProvider")]
5226 #[serde(default)]
5227 pub inlay_hint_provider: Option<
5228 BooleanOrInlayHintOptionsOrInlayHintRegistrationOptions,
5229 >,
5230 #[serde(rename = "diagnosticProvider")]
5234 #[serde(default)]
5235 pub diagnostic_provider: Option<DiagnosticOptionsOrDiagnosticRegistrationOptions>,
5236 #[serde(rename = "inlineCompletionProvider")]
5240 #[serde(default)]
5241 pub inline_completion_provider: Option<BooleanOrInlineCompletionOptions>,
5242 #[serde(default)]
5244 pub workspace: Option<WorkspaceOptions>,
5245 #[serde(default)]
5247 pub experimental: Option<LSPAny>,
5248}
5249#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5254#[serde(rename_all = "camelCase")]
5255pub struct ServerInfo {
5256 pub name: String,
5258 #[serde(default)]
5260 pub version: Option<String>,
5261}
5262#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5264#[serde(rename_all = "camelCase")]
5265pub struct VersionedTextDocumentIdentifier {
5266 #[serde(flatten)]
5267 pub text_document_identifier_base: TextDocumentIdentifier,
5268 pub version: Integer,
5270}
5271#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5273#[serde(rename_all = "camelCase")]
5274pub struct SaveOptions {
5275 #[serde(rename = "includeText")]
5277 #[serde(default)]
5278 pub include_text: Option<bool>,
5279}
5280#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5282#[serde(rename_all = "camelCase")]
5283pub struct FileEvent {
5284 pub uri: DocumentUri,
5286 pub type_: FileChangeType,
5288}
5289#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5290#[serde(rename_all = "camelCase")]
5291pub struct FileSystemWatcher {
5292 #[serde(rename = "globPattern")]
5296 pub glob_pattern: GlobPattern,
5297 #[serde(default)]
5301 pub kind: Option<WatchKind>,
5302}
5303#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5306#[serde(rename_all = "camelCase")]
5307pub struct Diagnostic {
5308 pub range: Range,
5310 #[serde(default)]
5314 pub severity: Option<DiagnosticSeverity>,
5315 #[serde(default)]
5317 pub code: Option<IntegerOrString>,
5318 #[serde(rename = "codeDescription")]
5323 #[serde(default)]
5324 pub code_description: Option<CodeDescription>,
5325 #[serde(default)]
5329 pub source: Option<String>,
5330 pub message: MarkupContentOrString,
5335 #[serde(default)]
5339 pub tags: Option<Vec<DiagnosticTag>>,
5340 #[serde(rename = "relatedInformation")]
5343 #[serde(default)]
5344 pub related_information: Option<Vec<DiagnosticRelatedInformation>>,
5345 #[serde(default)]
5350 pub data: Option<LSPAny>,
5351}
5352#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5354#[serde(rename_all = "camelCase")]
5355pub struct CompletionContext {
5356 #[serde(rename = "triggerKind")]
5358 pub trigger_kind: CompletionTriggerKind,
5359 #[serde(rename = "triggerCharacter")]
5362 #[serde(default)]
5363 pub trigger_character: Option<String>,
5364}
5365#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5369#[serde(rename_all = "camelCase")]
5370pub struct CompletionItemLabelDetails {
5371 #[serde(default)]
5374 pub detail: Option<String>,
5375 #[serde(default)]
5378 pub description: Option<String>,
5379}
5380#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5384#[serde(rename_all = "camelCase")]
5385pub struct InsertReplaceEdit {
5386 #[serde(rename = "newText")]
5388 pub new_text: String,
5389 pub insert: Range,
5391 pub replace: Range,
5393}
5394#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5410#[serde(rename_all = "camelCase")]
5411pub struct CompletionItemDefaults {
5412 #[serde(rename = "commitCharacters")]
5416 #[serde(default)]
5417 pub commit_characters: Option<Vec<String>>,
5418 #[serde(rename = "editRange")]
5422 #[serde(default)]
5423 pub edit_range: Option<EditRangeWithInsertReplaceOrRange>,
5424 #[serde(rename = "insertTextFormat")]
5428 #[serde(default)]
5429 pub insert_text_format: Option<InsertTextFormat>,
5430 #[serde(rename = "insertTextMode")]
5434 #[serde(default)]
5435 pub insert_text_mode: Option<InsertTextMode>,
5436 #[serde(default)]
5440 pub data: Option<LSPAny>,
5441}
5442#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5460#[serde(rename_all = "camelCase")]
5461pub struct CompletionItemApplyKinds {
5462 #[serde(rename = "commitCharacters")]
5478 #[serde(default)]
5479 pub commit_characters: Option<ApplyKind>,
5480 #[serde(default)]
5503 pub data: Option<ApplyKind>,
5504}
5505#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5507#[serde(rename_all = "camelCase")]
5508pub struct CompletionOptions {
5509 #[serde(flatten)]
5510 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5511 #[serde(rename = "triggerCharacters")]
5520 #[serde(default)]
5521 pub trigger_characters: Option<Vec<String>>,
5522 #[serde(rename = "allCommitCharacters")]
5531 #[serde(default)]
5532 pub all_commit_characters: Option<Vec<String>>,
5533 #[serde(rename = "resolveProvider")]
5536 #[serde(default)]
5537 pub resolve_provider: Option<bool>,
5538 #[serde(rename = "completionItem")]
5543 #[serde(default)]
5544 pub completion_item: Option<ServerCompletionItemOptions>,
5545}
5546#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5548#[serde(rename_all = "camelCase")]
5549pub struct HoverOptions {
5550 #[serde(flatten)]
5551 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5552}
5553#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5557#[serde(rename_all = "camelCase")]
5558pub struct SignatureHelpContext {
5559 #[serde(rename = "triggerKind")]
5561 pub trigger_kind: SignatureHelpTriggerKind,
5562 #[serde(rename = "triggerCharacter")]
5566 #[serde(default)]
5567 pub trigger_character: Option<String>,
5568 #[serde(rename = "isRetrigger")]
5573 pub is_retrigger: bool,
5574 #[serde(rename = "activeSignatureHelp")]
5579 #[serde(default)]
5580 pub active_signature_help: Option<SignatureHelp>,
5581}
5582#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5586#[serde(rename_all = "camelCase")]
5587pub struct SignatureInformation {
5588 pub label: String,
5591 #[serde(default)]
5594 pub documentation: Option<MarkupContentOrString>,
5595 #[serde(default)]
5597 pub parameters: Option<Vec<ParameterInformation>>,
5598 #[serde(rename = "activeParameter")]
5610 #[serde(default)]
5611 pub active_parameter: Option<Option<Uinteger>>,
5612}
5613#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5615#[serde(rename_all = "camelCase")]
5616pub struct SignatureHelpOptions {
5617 #[serde(flatten)]
5618 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5619 #[serde(rename = "triggerCharacters")]
5621 #[serde(default)]
5622 pub trigger_characters: Option<Vec<String>>,
5623 #[serde(rename = "retriggerCharacters")]
5630 #[serde(default)]
5631 pub retrigger_characters: Option<Vec<String>>,
5632}
5633#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5635#[serde(rename_all = "camelCase")]
5636pub struct DefinitionOptions {
5637 #[serde(flatten)]
5638 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5639}
5640#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5643#[serde(rename_all = "camelCase")]
5644pub struct ReferenceContext {
5645 #[serde(rename = "includeDeclaration")]
5647 pub include_declaration: bool,
5648}
5649#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5651#[serde(rename_all = "camelCase")]
5652pub struct ReferenceOptions {
5653 #[serde(flatten)]
5654 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5655}
5656#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5658#[serde(rename_all = "camelCase")]
5659pub struct DocumentHighlightOptions {
5660 #[serde(flatten)]
5661 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5662}
5663#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5665#[serde(rename_all = "camelCase")]
5666pub struct BaseSymbolInformation {
5667 pub name: String,
5669 pub kind: SymbolKind,
5671 #[serde(default)]
5675 pub tags: Option<Vec<SymbolTag>>,
5676 #[serde(rename = "containerName")]
5681 #[serde(default)]
5682 pub container_name: Option<String>,
5683}
5684#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5686#[serde(rename_all = "camelCase")]
5687pub struct DocumentSymbolOptions {
5688 #[serde(flatten)]
5689 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5690 #[serde(default)]
5695 pub label: Option<String>,
5696}
5697#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5700#[serde(rename_all = "camelCase")]
5701pub struct CodeActionContext {
5702 pub diagnostics: Vec<Diagnostic>,
5708 #[serde(default)]
5713 pub only: Option<Vec<CodeActionKind>>,
5714 #[serde(rename = "triggerKind")]
5718 #[serde(default)]
5719 pub trigger_kind: Option<CodeActionTriggerKind>,
5720}
5721#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5725#[serde(rename_all = "camelCase")]
5726pub struct CodeActionDisabled {
5727 pub reason: String,
5731}
5732#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5734#[serde(rename_all = "camelCase")]
5735pub struct CodeActionOptions {
5736 #[serde(flatten)]
5737 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5738 #[serde(rename = "codeActionKinds")]
5743 #[serde(default)]
5744 pub code_action_kinds: Option<Vec<CodeActionKind>>,
5745 #[serde(default)]
5760 pub documentation: Option<Vec<CodeActionKindDocumentation>>,
5761 #[serde(rename = "resolveProvider")]
5766 #[serde(default)]
5767 pub resolve_provider: Option<bool>,
5768}
5769#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5773#[serde(rename_all = "camelCase")]
5774pub struct LocationUriOnly {
5775 pub uri: DocumentUri,
5776}
5777#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5779#[serde(rename_all = "camelCase")]
5780pub struct WorkspaceSymbolOptions {
5781 #[serde(flatten)]
5782 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5783 #[serde(rename = "resolveProvider")]
5788 #[serde(default)]
5789 pub resolve_provider: Option<bool>,
5790}
5791#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5793#[serde(rename_all = "camelCase")]
5794pub struct CodeLensOptions {
5795 #[serde(flatten)]
5796 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5797 #[serde(rename = "resolveProvider")]
5799 #[serde(default)]
5800 pub resolve_provider: Option<bool>,
5801}
5802#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5804#[serde(rename_all = "camelCase")]
5805pub struct DocumentLinkOptions {
5806 #[serde(flatten)]
5807 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5808 #[serde(rename = "resolveProvider")]
5810 #[serde(default)]
5811 pub resolve_provider: Option<bool>,
5812}
5813#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5815#[serde(rename_all = "camelCase")]
5816pub struct FormattingOptions {
5817 #[serde(rename = "tabSize")]
5819 pub tab_size: Uinteger,
5820 #[serde(rename = "insertSpaces")]
5822 pub insert_spaces: bool,
5823 #[serde(rename = "trimTrailingWhitespace")]
5827 #[serde(default)]
5828 pub trim_trailing_whitespace: Option<bool>,
5829 #[serde(rename = "insertFinalNewline")]
5833 #[serde(default)]
5834 pub insert_final_newline: Option<bool>,
5835 #[serde(rename = "trimFinalNewlines")]
5839 #[serde(default)]
5840 pub trim_final_newlines: Option<bool>,
5841}
5842#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5844#[serde(rename_all = "camelCase")]
5845pub struct DocumentFormattingOptions {
5846 #[serde(flatten)]
5847 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5848}
5849#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5851#[serde(rename_all = "camelCase")]
5852pub struct DocumentRangeFormattingOptions {
5853 #[serde(flatten)]
5854 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5855 #[serde(rename = "rangesSupport")]
5859 #[serde(default)]
5860 pub ranges_support: Option<bool>,
5861}
5862#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5864#[serde(rename_all = "camelCase")]
5865pub struct DocumentOnTypeFormattingOptions {
5866 #[serde(rename = "firstTriggerCharacter")]
5868 pub first_trigger_character: String,
5869 #[serde(rename = "moreTriggerCharacter")]
5871 #[serde(default)]
5872 pub more_trigger_character: Option<Vec<String>>,
5873}
5874#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5876#[serde(rename_all = "camelCase")]
5877pub struct RenameOptions {
5878 #[serde(flatten)]
5879 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5880 #[serde(rename = "prepareProvider")]
5884 #[serde(default)]
5885 pub prepare_provider: Option<bool>,
5886}
5887#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5889#[serde(rename_all = "camelCase")]
5890pub struct PrepareRenamePlaceholder {
5891 pub range: Range,
5892 pub placeholder: String,
5893}
5894#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5896#[serde(rename_all = "camelCase")]
5897pub struct PrepareRenameDefaultBehavior {
5898 #[serde(rename = "defaultBehavior")]
5899 pub default_behavior: bool,
5900}
5901#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5903#[serde(rename_all = "camelCase")]
5904pub struct ExecuteCommandOptions {
5905 #[serde(flatten)]
5906 pub work_done_progress_options_mixin: WorkDoneProgressOptions,
5907 pub commands: Vec<String>,
5909}
5910#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5914#[serde(rename_all = "camelCase")]
5915pub struct WorkspaceEditMetadata {
5916 #[serde(rename = "isRefactoring")]
5918 #[serde(default)]
5919 pub is_refactoring: Option<bool>,
5920}
5921#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5923#[serde(rename_all = "camelCase")]
5924pub struct SemanticTokensLegend {
5925 #[serde(rename = "tokenTypes")]
5927 pub token_types: Vec<String>,
5928 #[serde(rename = "tokenModifiers")]
5930 pub token_modifiers: Vec<String>,
5931}
5932#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5936#[serde(rename_all = "camelCase")]
5937pub struct SemanticTokensFullDelta {
5938 #[serde(default)]
5940 pub delta: Option<bool>,
5941}
5942#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5944#[serde(rename_all = "camelCase")]
5945pub struct OptionalVersionedTextDocumentIdentifier {
5946 #[serde(flatten)]
5947 pub text_document_identifier_base: TextDocumentIdentifier,
5948 pub version: Option<Integer>,
5954}
5955#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5959#[serde(rename_all = "camelCase")]
5960pub struct AnnotatedTextEdit {
5961 #[serde(flatten)]
5962 pub text_edit_base: TextEdit,
5963 #[serde(rename = "annotationId")]
5965 pub annotation_id: ChangeAnnotationIdentifier,
5966}
5967#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5971#[serde(rename_all = "camelCase")]
5972pub struct SnippetTextEdit {
5973 pub range: Range,
5975 pub snippet: StringValue,
5977 #[serde(rename = "annotationId")]
5979 #[serde(default)]
5980 pub annotation_id: Option<ChangeAnnotationIdentifier>,
5981}
5982#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5984#[serde(rename_all = "camelCase")]
5985pub struct ResourceOperation {
5986 pub kind: String,
5988 #[serde(rename = "annotationId")]
5992 #[serde(default)]
5993 pub annotation_id: Option<ChangeAnnotationIdentifier>,
5994}
5995#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
5997#[serde(rename_all = "camelCase")]
5998pub struct CreateFileOptions {
5999 #[serde(default)]
6001 pub overwrite: Option<bool>,
6002 #[serde(rename = "ignoreIfExists")]
6004 #[serde(default)]
6005 pub ignore_if_exists: Option<bool>,
6006}
6007#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6009#[serde(rename_all = "camelCase")]
6010pub struct RenameFileOptions {
6011 #[serde(default)]
6013 pub overwrite: Option<bool>,
6014 #[serde(rename = "ignoreIfExists")]
6016 #[serde(default)]
6017 pub ignore_if_exists: Option<bool>,
6018}
6019#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6021#[serde(rename_all = "camelCase")]
6022pub struct DeleteFileOptions {
6023 #[serde(default)]
6025 pub recursive: Option<bool>,
6026 #[serde(rename = "ignoreIfNotExists")]
6028 #[serde(default)]
6029 pub ignore_if_not_exists: Option<bool>,
6030}
6031#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6036#[serde(rename_all = "camelCase")]
6037pub struct FileOperationPattern {
6038 #[doc = "The glob pattern to match. Glob patterns can have the following syntax:\n- `*` to match zero or more characters in a path segment\n- `?` to match on one character in a path segment\n- `**` to match any number of path segments, including none\n- `{}` to group sub patterns into an OR expression. (e.g. `**\u{200b}/*.{ts,js}` matches all TypeScript and JavaScript files)\n- `[]` to declare a range of characters to match in a path segment (e.g., `example.[0-9]` to match on `example.0`, `example.1`, …)\n- `[!...]` to negate a range of characters to match in a path segment (e.g., `example.[!0-9]` to match on `example.a`, `example.b`, but not `example.0`)"]
6039 pub glob: String,
6040 #[serde(default)]
6044 pub matches: Option<FileOperationPatternKind>,
6045 #[serde(default)]
6047 pub options: Option<FileOperationPatternOptions>,
6048}
6049#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6053#[serde(rename_all = "camelCase")]
6054pub struct WorkspaceFullDocumentDiagnosticReport {
6055 #[serde(flatten)]
6056 pub full_document_diagnostic_report_base: FullDocumentDiagnosticReport,
6057 pub uri: DocumentUri,
6059 pub version: Option<Integer>,
6062}
6063#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6067#[serde(rename_all = "camelCase")]
6068pub struct WorkspaceUnchangedDocumentDiagnosticReport {
6069 #[serde(flatten)]
6070 pub unchanged_document_diagnostic_report_base: UnchangedDocumentDiagnosticReport,
6071 pub uri: DocumentUri,
6073 pub version: Option<Integer>,
6076}
6077#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6085#[serde(rename_all = "camelCase")]
6086pub struct NotebookCell {
6087 pub kind: NotebookCellKind,
6089 pub document: DocumentUri,
6092 #[serde(default)]
6096 pub metadata: Option<LSPObject>,
6097 #[serde(rename = "executionSummary")]
6100 #[serde(default)]
6101 pub execution_summary: Option<ExecutionSummary>,
6102}
6103#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6105#[serde(rename_all = "camelCase")]
6106pub struct NotebookDocumentFilterWithNotebook {
6107 pub notebook: NotebookDocumentFilterOrString,
6111 #[serde(default)]
6113 pub cells: Option<Vec<NotebookCellLanguage>>,
6114}
6115#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6117#[serde(rename_all = "camelCase")]
6118pub struct NotebookDocumentFilterWithCells {
6119 #[serde(default)]
6123 pub notebook: Option<NotebookDocumentFilterOrString>,
6124 pub cells: Vec<NotebookCellLanguage>,
6126}
6127#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6131#[serde(rename_all = "camelCase")]
6132pub struct NotebookDocumentCellChanges {
6133 #[serde(default)]
6136 pub structure: Option<NotebookDocumentCellChangeStructure>,
6137 #[serde(default)]
6140 pub data: Option<Vec<NotebookCell>>,
6141 #[serde(rename = "textContent")]
6143 #[serde(default)]
6144 pub text_content: Option<Vec<NotebookDocumentCellContentChanges>>,
6145}
6146#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6150#[serde(rename_all = "camelCase")]
6151pub struct SelectedCompletionInfo {
6152 pub range: Range,
6154 pub text: String,
6156}
6157#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6162#[serde(rename_all = "camelCase")]
6163pub struct ClientInfo {
6164 pub name: String,
6166 #[serde(default)]
6168 pub version: Option<String>,
6169}
6170#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6172#[serde(rename_all = "camelCase")]
6173pub struct ClientCapabilities {
6174 #[serde(default)]
6176 pub workspace: Option<WorkspaceClientCapabilities>,
6177 #[serde(rename = "textDocument")]
6179 #[serde(default)]
6180 pub text_document: Option<TextDocumentClientCapabilities>,
6181 #[serde(rename = "notebookDocument")]
6185 #[serde(default)]
6186 pub notebook_document: Option<NotebookDocumentClientCapabilities>,
6187 #[serde(default)]
6189 pub window: Option<WindowClientCapabilities>,
6190 #[serde(default)]
6194 pub general: Option<GeneralClientCapabilities>,
6195 #[serde(default)]
6197 pub experimental: Option<LSPAny>,
6198}
6199#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6200#[serde(rename_all = "camelCase")]
6201pub struct TextDocumentSyncOptions {
6202 #[serde(rename = "openClose")]
6205 #[serde(default)]
6206 pub open_close: Option<bool>,
6207 #[serde(default)]
6210 pub change: Option<TextDocumentSyncKind>,
6211 #[serde(rename = "willSave")]
6214 #[serde(default)]
6215 pub will_save: Option<bool>,
6216 #[serde(rename = "willSaveWaitUntil")]
6219 #[serde(default)]
6220 pub will_save_wait_until: Option<bool>,
6221 #[serde(default)]
6224 pub save: Option<BooleanOrSaveOptions>,
6225}
6226#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6230#[serde(rename_all = "camelCase")]
6231pub struct WorkspaceOptions {
6232 #[serde(rename = "workspaceFolders")]
6236 #[serde(default)]
6237 pub workspace_folders: Option<WorkspaceFoldersServerCapabilities>,
6238 #[serde(rename = "fileOperations")]
6242 #[serde(default)]
6243 pub file_operations: Option<FileOperationOptions>,
6244 #[serde(rename = "textDocumentContent")]
6248 #[serde(default)]
6249 pub text_document_content: Option<
6250 TextDocumentContentOptionsOrTextDocumentContentRegistrationOptions,
6251 >,
6252}
6253#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6255#[serde(rename_all = "camelCase")]
6256pub struct TextDocumentContentChangePartial {
6257 pub range: Range,
6259 #[serde(rename = "rangeLength")]
6263 #[serde(default)]
6264 pub range_length: Option<Uinteger>,
6265 pub text: String,
6267}
6268#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6270#[serde(rename_all = "camelCase")]
6271pub struct TextDocumentContentChangeWholeDocument {
6272 pub text: String,
6274}
6275#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6279#[serde(rename_all = "camelCase")]
6280pub struct CodeDescription {
6281 pub href: URI,
6283}
6284#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6288#[serde(rename_all = "camelCase")]
6289pub struct DiagnosticRelatedInformation {
6290 pub location: Location,
6292 pub message: String,
6294}
6295#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6299#[serde(rename_all = "camelCase")]
6300pub struct EditRangeWithInsertReplace {
6301 pub insert: Range,
6302 pub replace: Range,
6303}
6304#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6306#[serde(rename_all = "camelCase")]
6307pub struct ServerCompletionItemOptions {
6308 #[serde(rename = "labelDetailsSupport")]
6314 #[serde(default)]
6315 pub label_details_support: Option<bool>,
6316}
6317#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6320#[serde(rename_all = "camelCase")]
6321pub struct MarkedStringWithLanguage {
6322 pub language: String,
6323 pub value: String,
6324}
6325#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6328#[serde(rename_all = "camelCase")]
6329pub struct ParameterInformation {
6330 pub label: StringOrTupleOfUintegerAndUinteger,
6343 #[serde(default)]
6346 pub documentation: Option<MarkupContentOrString>,
6347}
6348#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6352#[serde(rename_all = "camelCase")]
6353pub struct CodeActionKindDocumentation {
6354 pub kind: CodeActionKind,
6360 pub command: Command,
6364}
6365#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6370#[serde(rename_all = "camelCase")]
6371pub struct NotebookCellTextDocumentFilter {
6372 pub notebook: NotebookDocumentFilterOrString,
6377 #[serde(default)]
6382 pub language: Option<String>,
6383}
6384#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6388#[serde(rename_all = "camelCase")]
6389pub struct FileOperationPatternOptions {
6390 #[serde(rename = "ignoreCase")]
6392 #[serde(default)]
6393 pub ignore_case: Option<bool>,
6394}
6395#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6396#[serde(rename_all = "camelCase")]
6397pub struct ExecutionSummary {
6398 #[serde(rename = "executionOrder")]
6402 pub execution_order: Uinteger,
6403 #[serde(default)]
6406 pub success: Option<bool>,
6407}
6408#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6410#[serde(rename_all = "camelCase")]
6411pub struct NotebookCellLanguage {
6412 pub language: String,
6413}
6414#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6418#[serde(rename_all = "camelCase")]
6419pub struct NotebookDocumentCellChangeStructure {
6420 pub array: NotebookCellArrayChange,
6422 #[serde(rename = "didOpen")]
6424 #[serde(default)]
6425 pub did_open: Option<Vec<TextDocumentItem>>,
6426 #[serde(rename = "didClose")]
6428 #[serde(default)]
6429 pub did_close: Option<Vec<TextDocumentIdentifier>>,
6430}
6431#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6435#[serde(rename_all = "camelCase")]
6436pub struct NotebookDocumentCellContentChanges {
6437 pub document: VersionedTextDocumentIdentifier,
6438 pub changes: Vec<TextDocumentContentChangeEvent>,
6439}
6440#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6442#[serde(rename_all = "camelCase")]
6443pub struct WorkspaceClientCapabilities {
6444 #[serde(rename = "applyEdit")]
6448 #[serde(default)]
6449 pub apply_edit: Option<bool>,
6450 #[serde(rename = "workspaceEdit")]
6452 #[serde(default)]
6453 pub workspace_edit: Option<WorkspaceEditClientCapabilities>,
6454 #[serde(rename = "didChangeConfiguration")]
6456 #[serde(default)]
6457 pub did_change_configuration: Option<DidChangeConfigurationClientCapabilities>,
6458 #[serde(rename = "didChangeWatchedFiles")]
6460 #[serde(default)]
6461 pub did_change_watched_files: Option<DidChangeWatchedFilesClientCapabilities>,
6462 #[serde(default)]
6464 pub symbol: Option<WorkspaceSymbolClientCapabilities>,
6465 #[serde(rename = "executeCommand")]
6467 #[serde(default)]
6468 pub execute_command: Option<ExecuteCommandClientCapabilities>,
6469 #[serde(rename = "workspaceFolders")]
6473 #[serde(default)]
6474 pub workspace_folders: Option<bool>,
6475 #[serde(default)]
6479 pub configuration: Option<bool>,
6480 #[serde(rename = "semanticTokens")]
6485 #[serde(default)]
6486 pub semantic_tokens: Option<SemanticTokensWorkspaceClientCapabilities>,
6487 #[serde(rename = "codeLens")]
6492 #[serde(default)]
6493 pub code_lens: Option<CodeLensWorkspaceClientCapabilities>,
6494 #[serde(rename = "fileOperations")]
6498 #[serde(default)]
6499 pub file_operations: Option<FileOperationClientCapabilities>,
6500 #[serde(rename = "inlineValue")]
6505 #[serde(default)]
6506 pub inline_value: Option<InlineValueWorkspaceClientCapabilities>,
6507 #[serde(rename = "inlayHint")]
6512 #[serde(default)]
6513 pub inlay_hint: Option<InlayHintWorkspaceClientCapabilities>,
6514 #[serde(default)]
6519 pub diagnostics: Option<DiagnosticWorkspaceClientCapabilities>,
6520 #[serde(rename = "foldingRange")]
6524 #[serde(default)]
6525 pub folding_range: Option<FoldingRangeWorkspaceClientCapabilities>,
6526 #[serde(rename = "textDocumentContent")]
6530 #[serde(default)]
6531 pub text_document_content: Option<TextDocumentContentClientCapabilities>,
6532}
6533#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6535#[serde(rename_all = "camelCase")]
6536pub struct TextDocumentClientCapabilities {
6537 #[serde(default)]
6539 pub synchronization: Option<TextDocumentSyncClientCapabilities>,
6540 #[serde(default)]
6544 pub filters: Option<TextDocumentFilterClientCapabilities>,
6545 #[serde(default)]
6547 pub completion: Option<CompletionClientCapabilities>,
6548 #[serde(default)]
6550 pub hover: Option<HoverClientCapabilities>,
6551 #[serde(rename = "signatureHelp")]
6553 #[serde(default)]
6554 pub signature_help: Option<SignatureHelpClientCapabilities>,
6555 #[serde(default)]
6559 pub declaration: Option<DeclarationClientCapabilities>,
6560 #[serde(default)]
6562 pub definition: Option<DefinitionClientCapabilities>,
6563 #[serde(rename = "typeDefinition")]
6567 #[serde(default)]
6568 pub type_definition: Option<TypeDefinitionClientCapabilities>,
6569 #[serde(default)]
6573 pub implementation: Option<ImplementationClientCapabilities>,
6574 #[serde(default)]
6576 pub references: Option<ReferenceClientCapabilities>,
6577 #[serde(rename = "documentHighlight")]
6579 #[serde(default)]
6580 pub document_highlight: Option<DocumentHighlightClientCapabilities>,
6581 #[serde(rename = "documentSymbol")]
6583 #[serde(default)]
6584 pub document_symbol: Option<DocumentSymbolClientCapabilities>,
6585 #[serde(rename = "codeAction")]
6587 #[serde(default)]
6588 pub code_action: Option<CodeActionClientCapabilities>,
6589 #[serde(rename = "codeLens")]
6591 #[serde(default)]
6592 pub code_lens: Option<CodeLensClientCapabilities>,
6593 #[serde(rename = "documentLink")]
6595 #[serde(default)]
6596 pub document_link: Option<DocumentLinkClientCapabilities>,
6597 #[serde(rename = "colorProvider")]
6602 #[serde(default)]
6603 pub color_provider: Option<DocumentColorClientCapabilities>,
6604 #[serde(default)]
6606 pub formatting: Option<DocumentFormattingClientCapabilities>,
6607 #[serde(rename = "rangeFormatting")]
6609 #[serde(default)]
6610 pub range_formatting: Option<DocumentRangeFormattingClientCapabilities>,
6611 #[serde(rename = "onTypeFormatting")]
6613 #[serde(default)]
6614 pub on_type_formatting: Option<DocumentOnTypeFormattingClientCapabilities>,
6615 #[serde(default)]
6617 pub rename: Option<RenameClientCapabilities>,
6618 #[serde(rename = "foldingRange")]
6622 #[serde(default)]
6623 pub folding_range: Option<FoldingRangeClientCapabilities>,
6624 #[serde(rename = "selectionRange")]
6628 #[serde(default)]
6629 pub selection_range: Option<SelectionRangeClientCapabilities>,
6630 #[serde(rename = "publishDiagnostics")]
6632 #[serde(default)]
6633 pub publish_diagnostics: Option<PublishDiagnosticsClientCapabilities>,
6634 #[serde(rename = "callHierarchy")]
6638 #[serde(default)]
6639 pub call_hierarchy: Option<CallHierarchyClientCapabilities>,
6640 #[serde(rename = "semanticTokens")]
6644 #[serde(default)]
6645 pub semantic_tokens: Option<SemanticTokensClientCapabilities>,
6646 #[serde(rename = "linkedEditingRange")]
6650 #[serde(default)]
6651 pub linked_editing_range: Option<LinkedEditingRangeClientCapabilities>,
6652 #[serde(default)]
6656 pub moniker: Option<MonikerClientCapabilities>,
6657 #[serde(rename = "typeHierarchy")]
6661 #[serde(default)]
6662 pub type_hierarchy: Option<TypeHierarchyClientCapabilities>,
6663 #[serde(rename = "inlineValue")]
6667 #[serde(default)]
6668 pub inline_value: Option<InlineValueClientCapabilities>,
6669 #[serde(rename = "inlayHint")]
6673 #[serde(default)]
6674 pub inlay_hint: Option<InlayHintClientCapabilities>,
6675 #[serde(default)]
6679 pub diagnostic: Option<DiagnosticClientCapabilities>,
6680 #[serde(rename = "inlineCompletion")]
6684 #[serde(default)]
6685 pub inline_completion: Option<InlineCompletionClientCapabilities>,
6686}
6687#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6691#[serde(rename_all = "camelCase")]
6692pub struct NotebookDocumentClientCapabilities {
6693 pub synchronization: NotebookDocumentSyncClientCapabilities,
6697}
6698#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6699#[serde(rename_all = "camelCase")]
6700pub struct WindowClientCapabilities {
6701 #[serde(rename = "workDoneProgress")]
6711 #[serde(default)]
6712 pub work_done_progress: Option<bool>,
6713 #[serde(rename = "showMessage")]
6717 #[serde(default)]
6718 pub show_message: Option<ShowMessageRequestClientCapabilities>,
6719 #[serde(rename = "showDocument")]
6723 #[serde(default)]
6724 pub show_document: Option<ShowDocumentClientCapabilities>,
6725}
6726#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6730#[serde(rename_all = "camelCase")]
6731pub struct GeneralClientCapabilities {
6732 #[serde(rename = "staleRequestSupport")]
6739 #[serde(default)]
6740 pub stale_request_support: Option<StaleRequestSupportOptions>,
6741 #[serde(rename = "regularExpressions")]
6745 #[serde(default)]
6746 pub regular_expressions: Option<RegularExpressionsClientCapabilities>,
6747 #[serde(default)]
6751 pub markdown: Option<MarkdownClientCapabilities>,
6752 #[serde(rename = "positionEncodings")]
6771 #[serde(default)]
6772 pub position_encodings: Option<Vec<PositionEncodingKind>>,
6773}
6774#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6775#[serde(rename_all = "camelCase")]
6776pub struct WorkspaceFoldersServerCapabilities {
6777 #[serde(default)]
6779 pub supported: Option<bool>,
6780 #[serde(rename = "changeNotifications")]
6788 #[serde(default)]
6789 pub change_notifications: Option<BooleanOrString>,
6790}
6791#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6795#[serde(rename_all = "camelCase")]
6796pub struct FileOperationOptions {
6797 #[serde(rename = "didCreate")]
6799 #[serde(default)]
6800 pub did_create: Option<FileOperationRegistrationOptions>,
6801 #[serde(rename = "willCreate")]
6803 #[serde(default)]
6804 pub will_create: Option<FileOperationRegistrationOptions>,
6805 #[serde(rename = "didRename")]
6807 #[serde(default)]
6808 pub did_rename: Option<FileOperationRegistrationOptions>,
6809 #[serde(rename = "willRename")]
6811 #[serde(default)]
6812 pub will_rename: Option<FileOperationRegistrationOptions>,
6813 #[serde(rename = "didDelete")]
6815 #[serde(default)]
6816 pub did_delete: Option<FileOperationRegistrationOptions>,
6817 #[serde(rename = "willDelete")]
6819 #[serde(default)]
6820 pub will_delete: Option<FileOperationRegistrationOptions>,
6821}
6822#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6828#[serde(rename_all = "camelCase")]
6829pub struct RelativePattern {
6830 #[serde(rename = "baseUri")]
6833 pub base_uri: UriOrWorkspaceFolder,
6834 pub pattern: Pattern,
6836}
6837#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6841#[serde(rename_all = "camelCase")]
6842pub struct TextDocumentFilterLanguage {
6843 pub language: String,
6845 #[serde(default)]
6847 pub scheme: Option<String>,
6848 #[doc = "A glob pattern, like **\u{200b}/*.{ts,js}. See TextDocumentFilter for examples.\n\n@since 3.18.0 - support for relative patterns. Whether clients support\nrelative patterns depends on the client capability\n`textDocuments.filters.relativePatternSupport`."]
6849 #[serde(default)]
6850 pub pattern: Option<GlobPattern>,
6851}
6852#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6856#[serde(rename_all = "camelCase")]
6857pub struct TextDocumentFilterScheme {
6858 #[serde(default)]
6860 pub language: Option<String>,
6861 pub scheme: String,
6863 #[doc = "A glob pattern, like **\u{200b}/*.{ts,js}. See TextDocumentFilter for examples.\n\n@since 3.18.0 - support for relative patterns. Whether clients support\nrelative patterns depends on the client capability\n`textDocuments.filters.relativePatternSupport`."]
6864 #[serde(default)]
6865 pub pattern: Option<GlobPattern>,
6866}
6867#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6871#[serde(rename_all = "camelCase")]
6872pub struct TextDocumentFilterPattern {
6873 #[serde(default)]
6875 pub language: Option<String>,
6876 #[serde(default)]
6878 pub scheme: Option<String>,
6879 #[doc = "A glob pattern, like **\u{200b}/*.{ts,js}. See TextDocumentFilter for examples.\n\n@since 3.18.0 - support for relative patterns. Whether clients support\nrelative patterns depends on the client capability\n`textDocuments.filters.relativePatternSupport`."]
6880 pub pattern: GlobPattern,
6881}
6882#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6886#[serde(rename_all = "camelCase")]
6887pub struct NotebookDocumentFilterNotebookType {
6888 #[serde(rename = "notebookType")]
6890 pub notebook_type: String,
6891 #[serde(default)]
6893 pub scheme: Option<String>,
6894 #[serde(default)]
6896 pub pattern: Option<GlobPattern>,
6897}
6898#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6902#[serde(rename_all = "camelCase")]
6903pub struct NotebookDocumentFilterScheme {
6904 #[serde(rename = "notebookType")]
6906 #[serde(default)]
6907 pub notebook_type: Option<String>,
6908 pub scheme: String,
6910 #[serde(default)]
6912 pub pattern: Option<GlobPattern>,
6913}
6914#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6918#[serde(rename_all = "camelCase")]
6919pub struct NotebookDocumentFilterPattern {
6920 #[serde(rename = "notebookType")]
6922 #[serde(default)]
6923 pub notebook_type: Option<String>,
6924 #[serde(default)]
6926 pub scheme: Option<String>,
6927 pub pattern: GlobPattern,
6929}
6930#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6935#[serde(rename_all = "camelCase")]
6936pub struct NotebookCellArrayChange {
6937 pub start: Uinteger,
6939 #[serde(rename = "deleteCount")]
6941 pub delete_count: Uinteger,
6942 #[serde(default)]
6944 pub cells: Option<Vec<NotebookCell>>,
6945}
6946#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6947#[serde(rename_all = "camelCase")]
6948pub struct WorkspaceEditClientCapabilities {
6949 #[serde(rename = "documentChanges")]
6951 #[serde(default)]
6952 pub document_changes: Option<bool>,
6953 #[serde(rename = "resourceOperations")]
6958 #[serde(default)]
6959 pub resource_operations: Option<Vec<ResourceOperationKind>>,
6960 #[serde(rename = "failureHandling")]
6965 #[serde(default)]
6966 pub failure_handling: Option<FailureHandlingKind>,
6967 #[serde(rename = "normalizesLineEndings")]
6975 #[serde(default)]
6976 pub normalizes_line_endings: Option<bool>,
6977 #[serde(rename = "changeAnnotationSupport")]
6982 #[serde(default)]
6983 pub change_annotation_support: Option<ChangeAnnotationsSupportOptions>,
6984 #[serde(rename = "metadataSupport")]
6988 #[serde(default)]
6989 pub metadata_support: Option<bool>,
6990 #[serde(rename = "snippetEditSupport")]
6994 #[serde(default)]
6995 pub snippet_edit_support: Option<bool>,
6996}
6997#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
6998#[serde(rename_all = "camelCase")]
6999pub struct DidChangeConfigurationClientCapabilities {
7000 #[serde(rename = "dynamicRegistration")]
7002 #[serde(default)]
7003 pub dynamic_registration: Option<bool>,
7004}
7005#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7006#[serde(rename_all = "camelCase")]
7007pub struct DidChangeWatchedFilesClientCapabilities {
7008 #[serde(rename = "dynamicRegistration")]
7012 #[serde(default)]
7013 pub dynamic_registration: Option<bool>,
7014 #[serde(rename = "relativePatternSupport")]
7019 #[serde(default)]
7020 pub relative_pattern_support: Option<bool>,
7021}
7022#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7024#[serde(rename_all = "camelCase")]
7025pub struct WorkspaceSymbolClientCapabilities {
7026 #[serde(rename = "dynamicRegistration")]
7028 #[serde(default)]
7029 pub dynamic_registration: Option<bool>,
7030 #[serde(rename = "symbolKind")]
7032 #[serde(default)]
7033 pub symbol_kind: Option<ClientSymbolKindOptions>,
7034 #[serde(rename = "tagSupport")]
7039 #[serde(default)]
7040 pub tag_support: Option<ClientSymbolTagOptions>,
7041 #[serde(rename = "resolveSupport")]
7047 #[serde(default)]
7048 pub resolve_support: Option<ClientSymbolResolveOptions>,
7049}
7050#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7052#[serde(rename_all = "camelCase")]
7053pub struct ExecuteCommandClientCapabilities {
7054 #[serde(rename = "dynamicRegistration")]
7056 #[serde(default)]
7057 pub dynamic_registration: Option<bool>,
7058}
7059#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7061#[serde(rename_all = "camelCase")]
7062pub struct SemanticTokensWorkspaceClientCapabilities {
7063 #[serde(rename = "refreshSupport")]
7071 #[serde(default)]
7072 pub refresh_support: Option<bool>,
7073}
7074#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7076#[serde(rename_all = "camelCase")]
7077pub struct CodeLensWorkspaceClientCapabilities {
7078 #[serde(rename = "refreshSupport")]
7086 #[serde(default)]
7087 pub refresh_support: Option<bool>,
7088}
7089#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7096#[serde(rename_all = "camelCase")]
7097pub struct FileOperationClientCapabilities {
7098 #[serde(rename = "dynamicRegistration")]
7100 #[serde(default)]
7101 pub dynamic_registration: Option<bool>,
7102 #[serde(rename = "didCreate")]
7104 #[serde(default)]
7105 pub did_create: Option<bool>,
7106 #[serde(rename = "willCreate")]
7108 #[serde(default)]
7109 pub will_create: Option<bool>,
7110 #[serde(rename = "didRename")]
7112 #[serde(default)]
7113 pub did_rename: Option<bool>,
7114 #[serde(rename = "willRename")]
7116 #[serde(default)]
7117 pub will_rename: Option<bool>,
7118 #[serde(rename = "didDelete")]
7120 #[serde(default)]
7121 pub did_delete: Option<bool>,
7122 #[serde(rename = "willDelete")]
7124 #[serde(default)]
7125 pub will_delete: Option<bool>,
7126}
7127#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7131#[serde(rename_all = "camelCase")]
7132pub struct InlineValueWorkspaceClientCapabilities {
7133 #[serde(rename = "refreshSupport")]
7141 #[serde(default)]
7142 pub refresh_support: Option<bool>,
7143}
7144#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7148#[serde(rename_all = "camelCase")]
7149pub struct InlayHintWorkspaceClientCapabilities {
7150 #[serde(rename = "refreshSupport")]
7158 #[serde(default)]
7159 pub refresh_support: Option<bool>,
7160}
7161#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7165#[serde(rename_all = "camelCase")]
7166pub struct DiagnosticWorkspaceClientCapabilities {
7167 #[serde(rename = "refreshSupport")]
7175 #[serde(default)]
7176 pub refresh_support: Option<bool>,
7177}
7178#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7182#[serde(rename_all = "camelCase")]
7183pub struct FoldingRangeWorkspaceClientCapabilities {
7184 #[serde(rename = "refreshSupport")]
7194 #[serde(default)]
7195 pub refresh_support: Option<bool>,
7196}
7197#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7201#[serde(rename_all = "camelCase")]
7202pub struct TextDocumentContentClientCapabilities {
7203 #[serde(rename = "dynamicRegistration")]
7205 #[serde(default)]
7206 pub dynamic_registration: Option<bool>,
7207}
7208#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7209#[serde(rename_all = "camelCase")]
7210pub struct TextDocumentSyncClientCapabilities {
7211 #[serde(rename = "dynamicRegistration")]
7213 #[serde(default)]
7214 pub dynamic_registration: Option<bool>,
7215 #[serde(rename = "willSave")]
7217 #[serde(default)]
7218 pub will_save: Option<bool>,
7219 #[serde(rename = "willSaveWaitUntil")]
7223 #[serde(default)]
7224 pub will_save_wait_until: Option<bool>,
7225 #[serde(rename = "didSave")]
7227 #[serde(default)]
7228 pub did_save: Option<bool>,
7229}
7230#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7231#[serde(rename_all = "camelCase")]
7232pub struct TextDocumentFilterClientCapabilities {
7233 #[serde(rename = "relativePatternSupport")]
7237 #[serde(default)]
7238 pub relative_pattern_support: Option<bool>,
7239}
7240#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7242#[serde(rename_all = "camelCase")]
7243pub struct CompletionClientCapabilities {
7244 #[serde(rename = "dynamicRegistration")]
7246 #[serde(default)]
7247 pub dynamic_registration: Option<bool>,
7248 #[serde(rename = "completionItem")]
7251 #[serde(default)]
7252 pub completion_item: Option<ClientCompletionItemOptions>,
7253 #[serde(rename = "completionItemKind")]
7255 #[serde(default)]
7256 pub completion_item_kind: Option<ClientCompletionItemOptionsKind>,
7257 #[serde(rename = "insertTextMode")]
7263 #[serde(default)]
7264 pub insert_text_mode: Option<InsertTextMode>,
7265 #[serde(rename = "contextSupport")]
7268 #[serde(default)]
7269 pub context_support: Option<bool>,
7270 #[serde(rename = "completionList")]
7275 #[serde(default)]
7276 pub completion_list: Option<CompletionListCapabilities>,
7277}
7278#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7279#[serde(rename_all = "camelCase")]
7280pub struct HoverClientCapabilities {
7281 #[serde(rename = "dynamicRegistration")]
7283 #[serde(default)]
7284 pub dynamic_registration: Option<bool>,
7285 #[serde(rename = "contentFormat")]
7288 #[serde(default)]
7289 pub content_format: Option<Vec<MarkupKind>>,
7290}
7291#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7293#[serde(rename_all = "camelCase")]
7294pub struct SignatureHelpClientCapabilities {
7295 #[serde(rename = "dynamicRegistration")]
7297 #[serde(default)]
7298 pub dynamic_registration: Option<bool>,
7299 #[serde(rename = "signatureInformation")]
7302 #[serde(default)]
7303 pub signature_information: Option<ClientSignatureInformationOptions>,
7304 #[serde(rename = "contextSupport")]
7311 #[serde(default)]
7312 pub context_support: Option<bool>,
7313}
7314#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7316#[serde(rename_all = "camelCase")]
7317pub struct DeclarationClientCapabilities {
7318 #[serde(rename = "dynamicRegistration")]
7322 #[serde(default)]
7323 pub dynamic_registration: Option<bool>,
7324 #[serde(rename = "linkSupport")]
7326 #[serde(default)]
7327 pub link_support: Option<bool>,
7328}
7329#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7331#[serde(rename_all = "camelCase")]
7332pub struct DefinitionClientCapabilities {
7333 #[serde(rename = "dynamicRegistration")]
7335 #[serde(default)]
7336 pub dynamic_registration: Option<bool>,
7337 #[serde(rename = "linkSupport")]
7341 #[serde(default)]
7342 pub link_support: Option<bool>,
7343}
7344#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7346#[serde(rename_all = "camelCase")]
7347pub struct TypeDefinitionClientCapabilities {
7348 #[serde(rename = "dynamicRegistration")]
7352 #[serde(default)]
7353 pub dynamic_registration: Option<bool>,
7354 #[serde(rename = "linkSupport")]
7358 #[serde(default)]
7359 pub link_support: Option<bool>,
7360}
7361#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7363#[serde(rename_all = "camelCase")]
7364pub struct ImplementationClientCapabilities {
7365 #[serde(rename = "dynamicRegistration")]
7369 #[serde(default)]
7370 pub dynamic_registration: Option<bool>,
7371 #[serde(rename = "linkSupport")]
7375 #[serde(default)]
7376 pub link_support: Option<bool>,
7377}
7378#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7380#[serde(rename_all = "camelCase")]
7381pub struct ReferenceClientCapabilities {
7382 #[serde(rename = "dynamicRegistration")]
7384 #[serde(default)]
7385 pub dynamic_registration: Option<bool>,
7386}
7387#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7389#[serde(rename_all = "camelCase")]
7390pub struct DocumentHighlightClientCapabilities {
7391 #[serde(rename = "dynamicRegistration")]
7393 #[serde(default)]
7394 pub dynamic_registration: Option<bool>,
7395}
7396#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7398#[serde(rename_all = "camelCase")]
7399pub struct DocumentSymbolClientCapabilities {
7400 #[serde(rename = "dynamicRegistration")]
7402 #[serde(default)]
7403 pub dynamic_registration: Option<bool>,
7404 #[serde(rename = "symbolKind")]
7407 #[serde(default)]
7408 pub symbol_kind: Option<ClientSymbolKindOptions>,
7409 #[serde(rename = "hierarchicalDocumentSymbolSupport")]
7411 #[serde(default)]
7412 pub hierarchical_document_symbol_support: Option<bool>,
7413 #[serde(rename = "tagSupport")]
7419 #[serde(default)]
7420 pub tag_support: Option<ClientSymbolTagOptions>,
7421 #[serde(rename = "labelSupport")]
7426 #[serde(default)]
7427 pub label_support: Option<bool>,
7428}
7429#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7431#[serde(rename_all = "camelCase")]
7432pub struct CodeActionClientCapabilities {
7433 #[serde(rename = "dynamicRegistration")]
7435 #[serde(default)]
7436 pub dynamic_registration: Option<bool>,
7437 #[serde(rename = "codeActionLiteralSupport")]
7443 #[serde(default)]
7444 pub code_action_literal_support: Option<ClientCodeActionLiteralOptions>,
7445 #[serde(rename = "isPreferredSupport")]
7449 #[serde(default)]
7450 pub is_preferred_support: Option<bool>,
7451 #[serde(rename = "disabledSupport")]
7455 #[serde(default)]
7456 pub disabled_support: Option<bool>,
7457 #[serde(rename = "dataSupport")]
7463 #[serde(default)]
7464 pub data_support: Option<bool>,
7465 #[serde(rename = "resolveSupport")]
7470 #[serde(default)]
7471 pub resolve_support: Option<ClientCodeActionResolveOptions>,
7472 #[serde(rename = "honorsChangeAnnotations")]
7480 #[serde(default)]
7481 pub honors_change_annotations: Option<bool>,
7482 #[serde(rename = "documentationSupport")]
7487 #[serde(default)]
7488 pub documentation_support: Option<bool>,
7489 #[serde(rename = "tagSupport")]
7494 #[serde(default)]
7495 pub tag_support: Option<CodeActionTagOptions>,
7496}
7497#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7499#[serde(rename_all = "camelCase")]
7500pub struct CodeLensClientCapabilities {
7501 #[serde(rename = "dynamicRegistration")]
7503 #[serde(default)]
7504 pub dynamic_registration: Option<bool>,
7505 #[serde(rename = "resolveSupport")]
7510 #[serde(default)]
7511 pub resolve_support: Option<ClientCodeLensResolveOptions>,
7512}
7513#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7515#[serde(rename_all = "camelCase")]
7516pub struct DocumentLinkClientCapabilities {
7517 #[serde(rename = "dynamicRegistration")]
7519 #[serde(default)]
7520 pub dynamic_registration: Option<bool>,
7521 #[serde(rename = "tooltipSupport")]
7525 #[serde(default)]
7526 pub tooltip_support: Option<bool>,
7527}
7528#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7529#[serde(rename_all = "camelCase")]
7530pub struct DocumentColorClientCapabilities {
7531 #[serde(rename = "dynamicRegistration")]
7535 #[serde(default)]
7536 pub dynamic_registration: Option<bool>,
7537}
7538#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7540#[serde(rename_all = "camelCase")]
7541pub struct DocumentFormattingClientCapabilities {
7542 #[serde(rename = "dynamicRegistration")]
7544 #[serde(default)]
7545 pub dynamic_registration: Option<bool>,
7546}
7547#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7549#[serde(rename_all = "camelCase")]
7550pub struct DocumentRangeFormattingClientCapabilities {
7551 #[serde(rename = "dynamicRegistration")]
7553 #[serde(default)]
7554 pub dynamic_registration: Option<bool>,
7555 #[serde(rename = "rangesSupport")]
7559 #[serde(default)]
7560 pub ranges_support: Option<bool>,
7561}
7562#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7564#[serde(rename_all = "camelCase")]
7565pub struct DocumentOnTypeFormattingClientCapabilities {
7566 #[serde(rename = "dynamicRegistration")]
7568 #[serde(default)]
7569 pub dynamic_registration: Option<bool>,
7570}
7571#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7572#[serde(rename_all = "camelCase")]
7573pub struct RenameClientCapabilities {
7574 #[serde(rename = "dynamicRegistration")]
7576 #[serde(default)]
7577 pub dynamic_registration: Option<bool>,
7578 #[serde(rename = "prepareSupport")]
7583 #[serde(default)]
7584 pub prepare_support: Option<bool>,
7585 #[serde(rename = "prepareSupportDefaultBehavior")]
7592 #[serde(default)]
7593 pub prepare_support_default_behavior: Option<PrepareSupportDefaultBehavior>,
7594 #[serde(rename = "honorsChangeAnnotations")]
7602 #[serde(default)]
7603 pub honors_change_annotations: Option<bool>,
7604}
7605#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7606#[serde(rename_all = "camelCase")]
7607pub struct FoldingRangeClientCapabilities {
7608 #[serde(rename = "dynamicRegistration")]
7613 #[serde(default)]
7614 pub dynamic_registration: Option<bool>,
7615 #[serde(rename = "rangeLimit")]
7619 #[serde(default)]
7620 pub range_limit: Option<Uinteger>,
7621 #[serde(rename = "lineFoldingOnly")]
7625 #[serde(default)]
7626 pub line_folding_only: Option<bool>,
7627 #[serde(rename = "foldingRangeKind")]
7631 #[serde(default)]
7632 pub folding_range_kind: Option<ClientFoldingRangeKindOptions>,
7633 #[serde(rename = "foldingRange")]
7637 #[serde(default)]
7638 pub folding_range: Option<ClientFoldingRangeOptions>,
7639}
7640#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7641#[serde(rename_all = "camelCase")]
7642pub struct SelectionRangeClientCapabilities {
7643 #[serde(rename = "dynamicRegistration")]
7647 #[serde(default)]
7648 pub dynamic_registration: Option<bool>,
7649}
7650#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7652#[serde(rename_all = "camelCase")]
7653pub struct PublishDiagnosticsClientCapabilities {
7654 #[serde(flatten)]
7655 pub diagnostics_capabilities_base: DiagnosticsCapabilities,
7656 #[serde(rename = "versionSupport")]
7661 #[serde(default)]
7662 pub version_support: Option<bool>,
7663}
7664#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7666#[serde(rename_all = "camelCase")]
7667pub struct CallHierarchyClientCapabilities {
7668 #[serde(rename = "dynamicRegistration")]
7672 #[serde(default)]
7673 pub dynamic_registration: Option<bool>,
7674}
7675#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7677#[serde(rename_all = "camelCase")]
7678pub struct SemanticTokensClientCapabilities {
7679 #[serde(rename = "dynamicRegistration")]
7683 #[serde(default)]
7684 pub dynamic_registration: Option<bool>,
7685 pub requests: ClientSemanticTokensRequestOptions,
7694 #[serde(rename = "tokenTypes")]
7696 pub token_types: Vec<String>,
7697 #[serde(rename = "tokenModifiers")]
7699 pub token_modifiers: Vec<String>,
7700 pub formats: Vec<TokenFormat>,
7702 #[serde(rename = "overlappingTokenSupport")]
7704 #[serde(default)]
7705 pub overlapping_token_support: Option<bool>,
7706 #[serde(rename = "multilineTokenSupport")]
7708 #[serde(default)]
7709 pub multiline_token_support: Option<bool>,
7710 #[serde(rename = "serverCancelSupport")]
7717 #[serde(default)]
7718 pub server_cancel_support: Option<bool>,
7719 #[serde(rename = "augmentsSyntaxTokens")]
7730 #[serde(default)]
7731 pub augments_syntax_tokens: Option<bool>,
7732}
7733#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7737#[serde(rename_all = "camelCase")]
7738pub struct LinkedEditingRangeClientCapabilities {
7739 #[serde(rename = "dynamicRegistration")]
7743 #[serde(default)]
7744 pub dynamic_registration: Option<bool>,
7745}
7746#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7750#[serde(rename_all = "camelCase")]
7751pub struct MonikerClientCapabilities {
7752 #[serde(rename = "dynamicRegistration")]
7756 #[serde(default)]
7757 pub dynamic_registration: Option<bool>,
7758}
7759#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7761#[serde(rename_all = "camelCase")]
7762pub struct TypeHierarchyClientCapabilities {
7763 #[serde(rename = "dynamicRegistration")]
7767 #[serde(default)]
7768 pub dynamic_registration: Option<bool>,
7769}
7770#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7774#[serde(rename_all = "camelCase")]
7775pub struct InlineValueClientCapabilities {
7776 #[serde(rename = "dynamicRegistration")]
7778 #[serde(default)]
7779 pub dynamic_registration: Option<bool>,
7780}
7781#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7785#[serde(rename_all = "camelCase")]
7786pub struct InlayHintClientCapabilities {
7787 #[serde(rename = "dynamicRegistration")]
7789 #[serde(default)]
7790 pub dynamic_registration: Option<bool>,
7791 #[serde(rename = "resolveSupport")]
7794 #[serde(default)]
7795 pub resolve_support: Option<ClientInlayHintResolveOptions>,
7796}
7797#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7801#[serde(rename_all = "camelCase")]
7802pub struct DiagnosticClientCapabilities {
7803 #[serde(flatten)]
7804 pub diagnostics_capabilities_base: DiagnosticsCapabilities,
7805 #[serde(rename = "dynamicRegistration")]
7809 #[serde(default)]
7810 pub dynamic_registration: Option<bool>,
7811 #[serde(rename = "relatedDocumentSupport")]
7813 #[serde(default)]
7814 pub related_document_support: Option<bool>,
7815 #[serde(rename = "markupMessageSupport")]
7819 #[serde(default)]
7820 pub markup_message_support: Option<bool>,
7821}
7822#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7826#[serde(rename_all = "camelCase")]
7827pub struct InlineCompletionClientCapabilities {
7828 #[serde(rename = "dynamicRegistration")]
7830 #[serde(default)]
7831 pub dynamic_registration: Option<bool>,
7832}
7833#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7837#[serde(rename_all = "camelCase")]
7838pub struct NotebookDocumentSyncClientCapabilities {
7839 #[serde(rename = "dynamicRegistration")]
7844 #[serde(default)]
7845 pub dynamic_registration: Option<bool>,
7846 #[serde(rename = "executionSummarySupport")]
7848 #[serde(default)]
7849 pub execution_summary_support: Option<bool>,
7850}
7851#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7853#[serde(rename_all = "camelCase")]
7854pub struct ShowMessageRequestClientCapabilities {
7855 #[serde(rename = "messageActionItem")]
7857 #[serde(default)]
7858 pub message_action_item: Option<ClientShowMessageActionItemOptions>,
7859}
7860#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7864#[serde(rename_all = "camelCase")]
7865pub struct ShowDocumentClientCapabilities {
7866 pub support: bool,
7869}
7870#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7872#[serde(rename_all = "camelCase")]
7873pub struct StaleRequestSupportOptions {
7874 pub cancel: bool,
7876 #[serde(rename = "retryOnContentModified")]
7880 pub retry_on_content_modified: Vec<String>,
7881}
7882#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7886#[serde(rename_all = "camelCase")]
7887pub struct RegularExpressionsClientCapabilities {
7888 pub engine: RegularExpressionEngineKind,
7890 #[serde(default)]
7892 pub version: Option<String>,
7893}
7894#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7898#[serde(rename_all = "camelCase")]
7899pub struct MarkdownClientCapabilities {
7900 pub parser: String,
7902 #[serde(default)]
7904 pub version: Option<String>,
7905 #[serde(rename = "allowedTags")]
7910 #[serde(default)]
7911 pub allowed_tags: Option<Vec<String>>,
7912}
7913#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7915#[serde(rename_all = "camelCase")]
7916pub struct ChangeAnnotationsSupportOptions {
7917 #[serde(rename = "groupsOnLabel")]
7921 #[serde(default)]
7922 pub groups_on_label: Option<bool>,
7923}
7924#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7926#[serde(rename_all = "camelCase")]
7927pub struct ClientSymbolKindOptions {
7928 #[serde(rename = "valueSet")]
7937 #[serde(default)]
7938 pub value_set: Option<Vec<SymbolKind>>,
7939}
7940#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7942#[serde(rename_all = "camelCase")]
7943pub struct ClientSymbolTagOptions {
7944 #[serde(rename = "valueSet")]
7946 pub value_set: Vec<SymbolTag>,
7947}
7948#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7950#[serde(rename_all = "camelCase")]
7951pub struct ClientSymbolResolveOptions {
7952 pub properties: Vec<String>,
7955}
7956#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
7958#[serde(rename_all = "camelCase")]
7959pub struct ClientCompletionItemOptions {
7960 #[serde(rename = "snippetSupport")]
7967 #[serde(default)]
7968 pub snippet_support: Option<bool>,
7969 #[serde(rename = "commitCharactersSupport")]
7971 #[serde(default)]
7972 pub commit_characters_support: Option<bool>,
7973 #[serde(rename = "documentationFormat")]
7976 #[serde(default)]
7977 pub documentation_format: Option<Vec<MarkupKind>>,
7978 #[serde(rename = "deprecatedSupport")]
7980 #[serde(default)]
7981 pub deprecated_support: Option<bool>,
7982 #[serde(rename = "preselectSupport")]
7984 #[serde(default)]
7985 pub preselect_support: Option<bool>,
7986 #[serde(rename = "tagSupport")]
7993 #[serde(default)]
7994 pub tag_support: Option<CompletionItemTagOptions>,
7995 #[serde(rename = "insertReplaceSupport")]
8000 #[serde(default)]
8001 pub insert_replace_support: Option<bool>,
8002 #[serde(rename = "resolveSupport")]
8008 #[serde(default)]
8009 pub resolve_support: Option<ClientCompletionItemResolveOptions>,
8010 #[serde(rename = "insertTextModeSupport")]
8016 #[serde(default)]
8017 pub insert_text_mode_support: Option<ClientCompletionItemInsertTextModeOptions>,
8018 #[serde(rename = "labelDetailsSupport")]
8023 #[serde(default)]
8024 pub label_details_support: Option<bool>,
8025}
8026#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8028#[serde(rename_all = "camelCase")]
8029pub struct ClientCompletionItemOptionsKind {
8030 #[serde(rename = "valueSet")]
8039 #[serde(default)]
8040 pub value_set: Option<Vec<CompletionItemKind>>,
8041}
8042#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8047#[serde(rename_all = "camelCase")]
8048pub struct CompletionListCapabilities {
8049 #[serde(rename = "itemDefaults")]
8058 #[serde(default)]
8059 pub item_defaults: Option<Vec<String>>,
8060 #[serde(rename = "applyKindSupport")]
8072 #[serde(default)]
8073 pub apply_kind_support: Option<bool>,
8074}
8075#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8077#[serde(rename_all = "camelCase")]
8078pub struct ClientSignatureInformationOptions {
8079 #[serde(rename = "documentationFormat")]
8082 #[serde(default)]
8083 pub documentation_format: Option<Vec<MarkupKind>>,
8084 #[serde(rename = "parameterInformation")]
8086 #[serde(default)]
8087 pub parameter_information: Option<ClientSignatureParameterInformationOptions>,
8088 #[serde(rename = "activeParameterSupport")]
8093 #[serde(default)]
8094 pub active_parameter_support: Option<bool>,
8095 #[serde(rename = "noActiveParameterSupport")]
8101 #[serde(default)]
8102 pub no_active_parameter_support: Option<bool>,
8103}
8104#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8106#[serde(rename_all = "camelCase")]
8107pub struct ClientCodeActionLiteralOptions {
8108 #[serde(rename = "codeActionKind")]
8111 pub code_action_kind: ClientCodeActionKindOptions,
8112}
8113#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8115#[serde(rename_all = "camelCase")]
8116pub struct ClientCodeActionResolveOptions {
8117 pub properties: Vec<String>,
8119}
8120#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8122#[serde(rename_all = "camelCase")]
8123pub struct CodeActionTagOptions {
8124 #[serde(rename = "valueSet")]
8126 pub value_set: Vec<CodeActionTag>,
8127}
8128#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8130#[serde(rename_all = "camelCase")]
8131pub struct ClientCodeLensResolveOptions {
8132 pub properties: Vec<String>,
8134}
8135#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8137#[serde(rename_all = "camelCase")]
8138pub struct ClientFoldingRangeKindOptions {
8139 #[serde(rename = "valueSet")]
8144 #[serde(default)]
8145 pub value_set: Option<Vec<FoldingRangeKind>>,
8146}
8147#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8149#[serde(rename_all = "camelCase")]
8150pub struct ClientFoldingRangeOptions {
8151 #[serde(rename = "collapsedText")]
8156 #[serde(default)]
8157 pub collapsed_text: Option<bool>,
8158}
8159#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8161#[serde(rename_all = "camelCase")]
8162pub struct DiagnosticsCapabilities {
8163 #[serde(rename = "relatedInformation")]
8165 #[serde(default)]
8166 pub related_information: Option<bool>,
8167 #[serde(rename = "tagSupport")]
8172 #[serde(default)]
8173 pub tag_support: Option<ClientDiagnosticsTagOptions>,
8174 #[serde(rename = "codeDescriptionSupport")]
8178 #[serde(default)]
8179 pub code_description_support: Option<bool>,
8180 #[serde(rename = "dataSupport")]
8186 #[serde(default)]
8187 pub data_support: Option<bool>,
8188}
8189#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8191#[serde(rename_all = "camelCase")]
8192pub struct ClientSemanticTokensRequestOptions {
8193 #[serde(default)]
8196 pub range: Option<BooleanOrLiteral57f9bf6390bb37d9>,
8197 #[serde(default)]
8200 pub full: Option<BooleanOrClientSemanticTokensRequestFullDelta>,
8201}
8202#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8204#[serde(rename_all = "camelCase")]
8205pub struct ClientInlayHintResolveOptions {
8206 pub properties: Vec<String>,
8208}
8209#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8211#[serde(rename_all = "camelCase")]
8212pub struct ClientShowMessageActionItemOptions {
8213 #[serde(rename = "additionalPropertiesSupport")]
8217 #[serde(default)]
8218 pub additional_properties_support: Option<bool>,
8219}
8220#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8222#[serde(rename_all = "camelCase")]
8223pub struct CompletionItemTagOptions {
8224 #[serde(rename = "valueSet")]
8226 pub value_set: Vec<CompletionItemTag>,
8227}
8228#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8230#[serde(rename_all = "camelCase")]
8231pub struct ClientCompletionItemResolveOptions {
8232 pub properties: Vec<String>,
8234}
8235#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8237#[serde(rename_all = "camelCase")]
8238pub struct ClientCompletionItemInsertTextModeOptions {
8239 #[serde(rename = "valueSet")]
8240 pub value_set: Vec<InsertTextMode>,
8241}
8242#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8244#[serde(rename_all = "camelCase")]
8245pub struct ClientSignatureParameterInformationOptions {
8246 #[serde(rename = "labelOffsetSupport")]
8251 #[serde(default)]
8252 pub label_offset_support: Option<bool>,
8253}
8254#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8256#[serde(rename_all = "camelCase")]
8257pub struct ClientCodeActionKindOptions {
8258 #[serde(rename = "valueSet")]
8263 pub value_set: Vec<CodeActionKind>,
8264}
8265#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8267#[serde(rename_all = "camelCase")]
8268pub struct ClientDiagnosticsTagOptions {
8269 #[serde(rename = "valueSet")]
8271 pub value_set: Vec<DiagnosticTag>,
8272}
8273#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8275#[serde(rename_all = "camelCase")]
8276pub struct ClientSemanticTokensRequestFullDelta {
8277 #[serde(default)]
8280 pub delta: Option<bool>,
8281}
8282#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8283#[serde(untagged)]
8284pub enum AnnotatedTextEditOrSnippetTextEditOrTextEdit {
8285 AnnotatedTextEdit(AnnotatedTextEdit),
8286 SnippetTextEdit(SnippetTextEdit),
8287 TextEdit(TextEdit),
8288}
8289#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8290#[serde(untagged)]
8291pub enum BooleanOrCallHierarchyOptionsOrCallHierarchyRegistrationOptions {
8292 CallHierarchyRegistrationOptions(CallHierarchyRegistrationOptions),
8293 CallHierarchyOptions(CallHierarchyOptions),
8294 Boolean(bool),
8295}
8296#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8297#[serde(untagged)]
8298pub enum BooleanOrClientSemanticTokensRequestFullDelta {
8299 ClientSemanticTokensRequestFullDelta(ClientSemanticTokensRequestFullDelta),
8300 Boolean(bool),
8301}
8302#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8303#[serde(untagged)]
8304pub enum BooleanOrCodeActionOptions {
8305 CodeActionOptions(CodeActionOptions),
8306 Boolean(bool),
8307}
8308#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8309#[serde(untagged)]
8310pub enum BooleanOrDecimalOrIntegerOrLSPArrayOrLSPObjectOrStringOrUinteger {
8311 LSPArray(LSPArray),
8312 LSPObject(LSPObject),
8313 Boolean(bool),
8314 Decimal(Decimal),
8315 Integer(Integer),
8316 String(String),
8317 Uinteger(Uinteger),
8318}
8319#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8320#[serde(untagged)]
8321pub enum BooleanOrDeclarationOptionsOrDeclarationRegistrationOptions {
8322 DeclarationRegistrationOptions(DeclarationRegistrationOptions),
8323 DeclarationOptions(DeclarationOptions),
8324 Boolean(bool),
8325}
8326#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8327#[serde(untagged)]
8328pub enum BooleanOrDefinitionOptions {
8329 DefinitionOptions(DefinitionOptions),
8330 Boolean(bool),
8331}
8332#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8333#[serde(untagged)]
8334pub enum BooleanOrDocumentColorOptionsOrDocumentColorRegistrationOptions {
8335 DocumentColorRegistrationOptions(DocumentColorRegistrationOptions),
8336 DocumentColorOptions(DocumentColorOptions),
8337 Boolean(bool),
8338}
8339#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8340#[serde(untagged)]
8341pub enum BooleanOrDocumentFormattingOptions {
8342 DocumentFormattingOptions(DocumentFormattingOptions),
8343 Boolean(bool),
8344}
8345#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8346#[serde(untagged)]
8347pub enum BooleanOrDocumentHighlightOptions {
8348 DocumentHighlightOptions(DocumentHighlightOptions),
8349 Boolean(bool),
8350}
8351#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8352#[serde(untagged)]
8353pub enum BooleanOrDocumentRangeFormattingOptions {
8354 DocumentRangeFormattingOptions(DocumentRangeFormattingOptions),
8355 Boolean(bool),
8356}
8357#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8358#[serde(untagged)]
8359pub enum BooleanOrDocumentSymbolOptions {
8360 DocumentSymbolOptions(DocumentSymbolOptions),
8361 Boolean(bool),
8362}
8363#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8364#[serde(untagged)]
8365pub enum BooleanOrFoldingRangeOptionsOrFoldingRangeRegistrationOptions {
8366 FoldingRangeRegistrationOptions(FoldingRangeRegistrationOptions),
8367 FoldingRangeOptions(FoldingRangeOptions),
8368 Boolean(bool),
8369}
8370#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8371#[serde(untagged)]
8372pub enum BooleanOrHoverOptions {
8373 HoverOptions(HoverOptions),
8374 Boolean(bool),
8375}
8376#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8377#[serde(untagged)]
8378pub enum BooleanOrImplementationOptionsOrImplementationRegistrationOptions {
8379 ImplementationRegistrationOptions(ImplementationRegistrationOptions),
8380 ImplementationOptions(ImplementationOptions),
8381 Boolean(bool),
8382}
8383#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8384#[serde(untagged)]
8385pub enum BooleanOrInlayHintOptionsOrInlayHintRegistrationOptions {
8386 InlayHintRegistrationOptions(InlayHintRegistrationOptions),
8387 InlayHintOptions(InlayHintOptions),
8388 Boolean(bool),
8389}
8390#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8391#[serde(untagged)]
8392pub enum BooleanOrInlineCompletionOptions {
8393 InlineCompletionOptions(InlineCompletionOptions),
8394 Boolean(bool),
8395}
8396#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8397#[serde(untagged)]
8398pub enum BooleanOrInlineValueOptionsOrInlineValueRegistrationOptions {
8399 InlineValueRegistrationOptions(InlineValueRegistrationOptions),
8400 InlineValueOptions(InlineValueOptions),
8401 Boolean(bool),
8402}
8403#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8404#[serde(untagged)]
8405pub enum BooleanOrLinkedEditingRangeOptionsOrLinkedEditingRangeRegistrationOptions {
8406 LinkedEditingRangeRegistrationOptions(LinkedEditingRangeRegistrationOptions),
8407 LinkedEditingRangeOptions(LinkedEditingRangeOptions),
8408 Boolean(bool),
8409}
8410#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8411#[serde(untagged)]
8412pub enum BooleanOrLiteral57f9bf6390bb37d9 {
8413 Literal57f9bf6390bb37d9(Literal57f9bf6390bb37d9),
8414 Boolean(bool),
8415}
8416#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8417#[serde(untagged)]
8418pub enum BooleanOrMonikerOptionsOrMonikerRegistrationOptions {
8419 MonikerRegistrationOptions(MonikerRegistrationOptions),
8420 MonikerOptions(MonikerOptions),
8421 Boolean(bool),
8422}
8423#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8424#[serde(untagged)]
8425pub enum BooleanOrReferenceOptions {
8426 ReferenceOptions(ReferenceOptions),
8427 Boolean(bool),
8428}
8429#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8430#[serde(untagged)]
8431pub enum BooleanOrRenameOptions {
8432 RenameOptions(RenameOptions),
8433 Boolean(bool),
8434}
8435#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8436#[serde(untagged)]
8437pub enum BooleanOrSaveOptions {
8438 SaveOptions(SaveOptions),
8439 Boolean(bool),
8440}
8441#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8442#[serde(untagged)]
8443pub enum BooleanOrSelectionRangeOptionsOrSelectionRangeRegistrationOptions {
8444 SelectionRangeRegistrationOptions(SelectionRangeRegistrationOptions),
8445 SelectionRangeOptions(SelectionRangeOptions),
8446 Boolean(bool),
8447}
8448#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8449#[serde(untagged)]
8450pub enum BooleanOrSemanticTokensFullDelta {
8451 SemanticTokensFullDelta(SemanticTokensFullDelta),
8452 Boolean(bool),
8453}
8454#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
8455#[serde(untagged)]
8456pub enum BooleanOrString {
8457 Boolean(bool),
8458 String(String),
8459}
8460#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8461#[serde(untagged)]
8462pub enum BooleanOrTypeDefinitionOptionsOrTypeDefinitionRegistrationOptions {
8463 TypeDefinitionRegistrationOptions(TypeDefinitionRegistrationOptions),
8464 TypeDefinitionOptions(TypeDefinitionOptions),
8465 Boolean(bool),
8466}
8467#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8468#[serde(untagged)]
8469pub enum BooleanOrTypeHierarchyOptionsOrTypeHierarchyRegistrationOptions {
8470 TypeHierarchyRegistrationOptions(TypeHierarchyRegistrationOptions),
8471 TypeHierarchyOptions(TypeHierarchyOptions),
8472 Boolean(bool),
8473}
8474#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8475#[serde(untagged)]
8476pub enum BooleanOrWorkspaceSymbolOptions {
8477 WorkspaceSymbolOptions(WorkspaceSymbolOptions),
8478 Boolean(bool),
8479}
8480#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8481#[serde(untagged)]
8482pub enum CodeActionOrCommand {
8483 CodeAction(CodeAction),
8484 Command(Command),
8485}
8486#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8487#[serde(untagged)]
8488pub enum CompletionItemArrayOrCompletionList {
8489 CompletionItemArray(Vec<CompletionItem>),
8490 CompletionList(CompletionList),
8491}
8492#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8493#[serde(untagged)]
8494pub enum CreateFileOrDeleteFileOrRenameFileOrTextDocumentEdit {
8495 RenameFile(RenameFile),
8496 CreateFile(CreateFile),
8497 DeleteFile(DeleteFile),
8498 TextDocumentEdit(TextDocumentEdit),
8499}
8500#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8501#[serde(untagged)]
8502pub enum DeclarationOrDeclarationLinkArray {
8503 Declaration(Declaration),
8504 DeclarationLinkArray(Vec<DeclarationLink>),
8505}
8506#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8507#[serde(untagged)]
8508pub enum DefinitionOrDefinitionLinkArray {
8509 Definition(Definition),
8510 DefinitionLinkArray(Vec<DefinitionLink>),
8511}
8512#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8513#[serde(untagged)]
8514pub enum DiagnosticOptionsOrDiagnosticRegistrationOptions {
8515 DiagnosticRegistrationOptions(DiagnosticRegistrationOptions),
8516 DiagnosticOptions(DiagnosticOptions),
8517}
8518#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8519#[serde(untagged)]
8520pub enum DocumentSymbolArrayOrSymbolInformationArray {
8521 DocumentSymbolArray(Vec<DocumentSymbol>),
8522 SymbolInformationArray(Vec<SymbolInformation>),
8523}
8524#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8525#[serde(untagged)]
8526pub enum EditRangeWithInsertReplaceOrRange {
8527 EditRangeWithInsertReplace(EditRangeWithInsertReplace),
8528 Range(Range),
8529}
8530#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8531#[serde(untagged)]
8532pub enum FullDocumentDiagnosticReportOrUnchangedDocumentDiagnosticReport {
8533 FullDocumentDiagnosticReport(FullDocumentDiagnosticReport),
8534 UnchangedDocumentDiagnosticReport(UnchangedDocumentDiagnosticReport),
8535}
8536#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8537#[serde(untagged)]
8538pub enum InlayHintLabelPartArrayOrString {
8539 InlayHintLabelPartArray(Vec<InlayHintLabelPart>),
8540 String(String),
8541}
8542#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8543#[serde(untagged)]
8544pub enum InlineCompletionItemArrayOrInlineCompletionList {
8545 InlineCompletionItemArray(Vec<InlineCompletionItem>),
8546 InlineCompletionList(InlineCompletionList),
8547}
8548#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8549#[serde(untagged)]
8550pub enum InlineValueEvaluatableExpressionOrInlineValueTextOrInlineValueVariableLookup {
8551 InlineValueVariableLookup(InlineValueVariableLookup),
8552 InlineValueEvaluatableExpression(InlineValueEvaluatableExpression),
8553 InlineValueText(InlineValueText),
8554}
8555#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8556#[serde(untagged)]
8557pub enum InsertReplaceEditOrTextEdit {
8558 InsertReplaceEdit(InsertReplaceEdit),
8559 TextEdit(TextEdit),
8560}
8561#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
8562#[serde(untagged)]
8563pub enum IntegerOrString {
8564 Integer(Integer),
8565 String(String),
8566}
8567#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8568#[serde(rename_all = "camelCase")]
8569pub struct Literal57f9bf6390bb37d9 {}
8570#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8571#[serde(untagged)]
8572pub enum LocationOrLocationArray {
8573 LocationArray(Vec<Location>),
8574 Location(Location),
8575}
8576#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8577#[serde(untagged)]
8578pub enum LocationOrLocationUriOnly {
8579 Location(Location),
8580 LocationUriOnly(LocationUriOnly),
8581}
8582#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8583#[serde(untagged)]
8584pub enum MarkedStringOrMarkedStringArrayOrMarkupContent {
8585 MarkedStringArray(Vec<MarkedString>),
8586 MarkedString(MarkedString),
8587 MarkupContent(MarkupContent),
8588}
8589#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8590#[serde(untagged)]
8591pub enum MarkedStringWithLanguageOrString {
8592 MarkedStringWithLanguage(MarkedStringWithLanguage),
8593 String(String),
8594}
8595#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8596#[serde(untagged)]
8597pub enum MarkupContentOrString {
8598 MarkupContent(MarkupContent),
8599 String(String),
8600}
8601#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8602#[serde(untagged)]
8603pub enum NotebookCellTextDocumentFilterOrTextDocumentFilter {
8604 TextDocumentFilter(TextDocumentFilter),
8605 NotebookCellTextDocumentFilter(NotebookCellTextDocumentFilter),
8606}
8607#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8608#[serde(untagged)]
8609pub enum NotebookDocumentFilterNotebookTypeOrNotebookDocumentFilterPatternOrNotebookDocumentFilterScheme {
8610 NotebookDocumentFilterNotebookType(NotebookDocumentFilterNotebookType),
8611 NotebookDocumentFilterPattern(NotebookDocumentFilterPattern),
8612 NotebookDocumentFilterScheme(NotebookDocumentFilterScheme),
8613}
8614#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8615#[serde(untagged)]
8616pub enum NotebookDocumentFilterOrString {
8617 NotebookDocumentFilter(NotebookDocumentFilter),
8618 String(String),
8619}
8620#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8621#[serde(untagged)]
8622pub enum NotebookDocumentFilterWithCellsOrNotebookDocumentFilterWithNotebook {
8623 NotebookDocumentFilterWithCells(NotebookDocumentFilterWithCells),
8624 NotebookDocumentFilterWithNotebook(NotebookDocumentFilterWithNotebook),
8625}
8626#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8627#[serde(untagged)]
8628pub enum NotebookDocumentSyncOptionsOrNotebookDocumentSyncRegistrationOptions {
8629 NotebookDocumentSyncRegistrationOptions(NotebookDocumentSyncRegistrationOptions),
8630 NotebookDocumentSyncOptions(NotebookDocumentSyncOptions),
8631}
8632#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8633#[serde(untagged)]
8634pub enum PatternOrRelativePattern {
8635 RelativePattern(RelativePattern),
8636 Pattern(Pattern),
8637}
8638#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8639#[serde(untagged)]
8640pub enum PrepareRenameDefaultBehaviorOrPrepareRenamePlaceholderOrRange {
8641 PrepareRenamePlaceholder(PrepareRenamePlaceholder),
8642 Range(Range),
8643 PrepareRenameDefaultBehavior(PrepareRenameDefaultBehavior),
8644}
8645#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8646#[serde(untagged)]
8647pub enum RelatedFullDocumentDiagnosticReportOrRelatedUnchangedDocumentDiagnosticReport {
8648 RelatedFullDocumentDiagnosticReport(RelatedFullDocumentDiagnosticReport),
8649 RelatedUnchangedDocumentDiagnosticReport(RelatedUnchangedDocumentDiagnosticReport),
8650}
8651#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8652#[serde(untagged)]
8653pub enum SemanticTokensOptionsOrSemanticTokensRegistrationOptions {
8654 SemanticTokensRegistrationOptions(SemanticTokensRegistrationOptions),
8655 SemanticTokensOptions(SemanticTokensOptions),
8656}
8657#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8658#[serde(untagged)]
8659pub enum SemanticTokensOrSemanticTokensDelta {
8660 SemanticTokens(SemanticTokens),
8661 SemanticTokensDelta(SemanticTokensDelta),
8662}
8663#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
8664#[serde(untagged)]
8665pub enum StringOrStringArray {
8666 StringArray(Vec<String>),
8667 String(String),
8668}
8669#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8670#[serde(untagged)]
8671pub enum StringOrStringValue {
8672 StringValue(StringValue),
8673 String(String),
8674}
8675#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
8676#[serde(untagged)]
8677pub enum StringOrTupleOfUintegerAndUinteger {
8678 TupleOfUintegerAndUinteger((Uinteger, Uinteger)),
8679 String(String),
8680}
8681#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8682#[serde(untagged)]
8683pub enum SymbolInformationArrayOrWorkspaceSymbolArray {
8684 SymbolInformationArray(Vec<SymbolInformation>),
8685 WorkspaceSymbolArray(Vec<WorkspaceSymbol>),
8686}
8687#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8688#[serde(untagged)]
8689pub enum TextDocumentContentChangePartialOrTextDocumentContentChangeWholeDocument {
8690 TextDocumentContentChangePartial(TextDocumentContentChangePartial),
8691 TextDocumentContentChangeWholeDocument(TextDocumentContentChangeWholeDocument),
8692}
8693#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8694#[serde(untagged)]
8695pub enum TextDocumentContentOptionsOrTextDocumentContentRegistrationOptions {
8696 TextDocumentContentRegistrationOptions(TextDocumentContentRegistrationOptions),
8697 TextDocumentContentOptions(TextDocumentContentOptions),
8698}
8699#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8700#[serde(untagged)]
8701pub enum TextDocumentFilterLanguageOrTextDocumentFilterPatternOrTextDocumentFilterScheme {
8702 TextDocumentFilterLanguage(TextDocumentFilterLanguage),
8703 TextDocumentFilterPattern(TextDocumentFilterPattern),
8704 TextDocumentFilterScheme(TextDocumentFilterScheme),
8705}
8706#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8707#[serde(untagged)]
8708pub enum TextDocumentSyncKindOrTextDocumentSyncOptions {
8709 TextDocumentSyncOptions(TextDocumentSyncOptions),
8710 TextDocumentSyncKind(TextDocumentSyncKind),
8711}
8712#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8713#[serde(untagged)]
8714pub enum UriOrWorkspaceFolder {
8715 WorkspaceFolder(WorkspaceFolder),
8716 Uri(URI),
8717}
8718#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
8719#[serde(untagged)]
8720pub enum WorkspaceFullDocumentDiagnosticReportOrWorkspaceUnchangedDocumentDiagnosticReport {
8721 WorkspaceFullDocumentDiagnosticReport(WorkspaceFullDocumentDiagnosticReport),
8722 WorkspaceUnchangedDocumentDiagnosticReport(
8723 WorkspaceUnchangedDocumentDiagnosticReport,
8724 ),
8725}
8726pub trait LspRequest {
8727 type Params: Serialize + for<'de> Deserialize<'de>;
8728 type Result: Serialize + for<'de> Deserialize<'de>;
8729 const METHOD: &'static str;
8730}
8731pub struct ImplementationRequest;
8732impl LspRequest for ImplementationRequest {
8733 type Params = ImplementationParams;
8734 type Result = Option<DefinitionOrDefinitionLinkArray>;
8735 const METHOD: &'static str = "textDocument/implementation";
8736}
8737pub struct TypeDefinitionRequest;
8738impl LspRequest for TypeDefinitionRequest {
8739 type Params = TypeDefinitionParams;
8740 type Result = Option<DefinitionOrDefinitionLinkArray>;
8741 const METHOD: &'static str = "textDocument/typeDefinition";
8742}
8743pub struct WorkspaceFoldersRequest;
8744impl LspRequest for WorkspaceFoldersRequest {
8745 type Params = ();
8746 type Result = Option<Vec<WorkspaceFolder>>;
8747 const METHOD: &'static str = "workspace/workspaceFolders";
8748}
8749pub struct ConfigurationRequest;
8750impl LspRequest for ConfigurationRequest {
8751 type Params = ConfigurationParams;
8752 type Result = Vec<LSPAny>;
8753 const METHOD: &'static str = "workspace/configuration";
8754}
8755pub struct DocumentColorRequest;
8756impl LspRequest for DocumentColorRequest {
8757 type Params = DocumentColorParams;
8758 type Result = Vec<ColorInformation>;
8759 const METHOD: &'static str = "textDocument/documentColor";
8760}
8761pub struct ColorPresentationRequest;
8762impl LspRequest for ColorPresentationRequest {
8763 type Params = ColorPresentationParams;
8764 type Result = Vec<ColorPresentation>;
8765 const METHOD: &'static str = "textDocument/colorPresentation";
8766}
8767pub struct FoldingRangeRequest;
8768impl LspRequest for FoldingRangeRequest {
8769 type Params = FoldingRangeParams;
8770 type Result = Option<Vec<FoldingRange>>;
8771 const METHOD: &'static str = "textDocument/foldingRange";
8772}
8773pub struct FoldingRangeRefreshRequest;
8774impl LspRequest for FoldingRangeRefreshRequest {
8775 type Params = ();
8776 type Result = ();
8777 const METHOD: &'static str = "workspace/foldingRange/refresh";
8778}
8779pub struct DeclarationRequest;
8780impl LspRequest for DeclarationRequest {
8781 type Params = DeclarationParams;
8782 type Result = Option<DeclarationOrDeclarationLinkArray>;
8783 const METHOD: &'static str = "textDocument/declaration";
8784}
8785pub struct SelectionRangeRequest;
8786impl LspRequest for SelectionRangeRequest {
8787 type Params = SelectionRangeParams;
8788 type Result = Option<Vec<SelectionRange>>;
8789 const METHOD: &'static str = "textDocument/selectionRange";
8790}
8791pub struct WorkDoneProgressCreateRequest;
8792impl LspRequest for WorkDoneProgressCreateRequest {
8793 type Params = WorkDoneProgressCreateParams;
8794 type Result = ();
8795 const METHOD: &'static str = "window/workDoneProgress/create";
8796}
8797pub struct CallHierarchyPrepareRequest;
8798impl LspRequest for CallHierarchyPrepareRequest {
8799 type Params = CallHierarchyPrepareParams;
8800 type Result = Option<Vec<CallHierarchyItem>>;
8801 const METHOD: &'static str = "textDocument/prepareCallHierarchy";
8802}
8803pub struct CallHierarchyIncomingCallsRequest;
8804impl LspRequest for CallHierarchyIncomingCallsRequest {
8805 type Params = CallHierarchyIncomingCallsParams;
8806 type Result = Option<Vec<CallHierarchyIncomingCall>>;
8807 const METHOD: &'static str = "callHierarchy/incomingCalls";
8808}
8809pub struct CallHierarchyOutgoingCallsRequest;
8810impl LspRequest for CallHierarchyOutgoingCallsRequest {
8811 type Params = CallHierarchyOutgoingCallsParams;
8812 type Result = Option<Vec<CallHierarchyOutgoingCall>>;
8813 const METHOD: &'static str = "callHierarchy/outgoingCalls";
8814}
8815pub struct SemanticTokensRequest;
8816impl LspRequest for SemanticTokensRequest {
8817 type Params = SemanticTokensParams;
8818 type Result = Option<SemanticTokens>;
8819 const METHOD: &'static str = "textDocument/semanticTokens/full";
8820}
8821pub struct SemanticTokensDeltaRequest;
8822impl LspRequest for SemanticTokensDeltaRequest {
8823 type Params = SemanticTokensDeltaParams;
8824 type Result = Option<SemanticTokensOrSemanticTokensDelta>;
8825 const METHOD: &'static str = "textDocument/semanticTokens/full/delta";
8826}
8827pub struct SemanticTokensRangeRequest;
8828impl LspRequest for SemanticTokensRangeRequest {
8829 type Params = SemanticTokensRangeParams;
8830 type Result = Option<SemanticTokens>;
8831 const METHOD: &'static str = "textDocument/semanticTokens/range";
8832}
8833pub struct SemanticTokensRefreshRequest;
8834impl LspRequest for SemanticTokensRefreshRequest {
8835 type Params = ();
8836 type Result = ();
8837 const METHOD: &'static str = "workspace/semanticTokens/refresh";
8838}
8839pub struct ShowDocumentRequest;
8840impl LspRequest for ShowDocumentRequest {
8841 type Params = ShowDocumentParams;
8842 type Result = ShowDocumentResult;
8843 const METHOD: &'static str = "window/showDocument";
8844}
8845pub struct LinkedEditingRangeRequest;
8846impl LspRequest for LinkedEditingRangeRequest {
8847 type Params = LinkedEditingRangeParams;
8848 type Result = Option<LinkedEditingRanges>;
8849 const METHOD: &'static str = "textDocument/linkedEditingRange";
8850}
8851pub struct WillCreateFilesRequest;
8852impl LspRequest for WillCreateFilesRequest {
8853 type Params = CreateFilesParams;
8854 type Result = Option<WorkspaceEdit>;
8855 const METHOD: &'static str = "workspace/willCreateFiles";
8856}
8857pub struct WillRenameFilesRequest;
8858impl LspRequest for WillRenameFilesRequest {
8859 type Params = RenameFilesParams;
8860 type Result = Option<WorkspaceEdit>;
8861 const METHOD: &'static str = "workspace/willRenameFiles";
8862}
8863pub struct WillDeleteFilesRequest;
8864impl LspRequest for WillDeleteFilesRequest {
8865 type Params = DeleteFilesParams;
8866 type Result = Option<WorkspaceEdit>;
8867 const METHOD: &'static str = "workspace/willDeleteFiles";
8868}
8869pub struct MonikerRequest;
8870impl LspRequest for MonikerRequest {
8871 type Params = MonikerParams;
8872 type Result = Option<Vec<Moniker>>;
8873 const METHOD: &'static str = "textDocument/moniker";
8874}
8875pub struct TypeHierarchyPrepareRequest;
8876impl LspRequest for TypeHierarchyPrepareRequest {
8877 type Params = TypeHierarchyPrepareParams;
8878 type Result = Option<Vec<TypeHierarchyItem>>;
8879 const METHOD: &'static str = "textDocument/prepareTypeHierarchy";
8880}
8881pub struct TypeHierarchySupertypesRequest;
8882impl LspRequest for TypeHierarchySupertypesRequest {
8883 type Params = TypeHierarchySupertypesParams;
8884 type Result = Option<Vec<TypeHierarchyItem>>;
8885 const METHOD: &'static str = "typeHierarchy/supertypes";
8886}
8887pub struct TypeHierarchySubtypesRequest;
8888impl LspRequest for TypeHierarchySubtypesRequest {
8889 type Params = TypeHierarchySubtypesParams;
8890 type Result = Option<Vec<TypeHierarchyItem>>;
8891 const METHOD: &'static str = "typeHierarchy/subtypes";
8892}
8893pub struct InlineValueRequest;
8894impl LspRequest for InlineValueRequest {
8895 type Params = InlineValueParams;
8896 type Result = Option<Vec<InlineValue>>;
8897 const METHOD: &'static str = "textDocument/inlineValue";
8898}
8899pub struct InlineValueRefreshRequest;
8900impl LspRequest for InlineValueRefreshRequest {
8901 type Params = ();
8902 type Result = ();
8903 const METHOD: &'static str = "workspace/inlineValue/refresh";
8904}
8905pub struct InlayHintRequest;
8906impl LspRequest for InlayHintRequest {
8907 type Params = InlayHintParams;
8908 type Result = Option<Vec<InlayHint>>;
8909 const METHOD: &'static str = "textDocument/inlayHint";
8910}
8911pub struct InlayHintResolveRequest;
8912impl LspRequest for InlayHintResolveRequest {
8913 type Params = InlayHint;
8914 type Result = InlayHint;
8915 const METHOD: &'static str = "inlayHint/resolve";
8916}
8917pub struct InlayHintRefreshRequest;
8918impl LspRequest for InlayHintRefreshRequest {
8919 type Params = ();
8920 type Result = ();
8921 const METHOD: &'static str = "workspace/inlayHint/refresh";
8922}
8923pub struct DocumentDiagnosticRequest;
8924impl LspRequest for DocumentDiagnosticRequest {
8925 type Params = DocumentDiagnosticParams;
8926 type Result = DocumentDiagnosticReport;
8927 const METHOD: &'static str = "textDocument/diagnostic";
8928}
8929pub struct WorkspaceDiagnosticRequest;
8930impl LspRequest for WorkspaceDiagnosticRequest {
8931 type Params = WorkspaceDiagnosticParams;
8932 type Result = WorkspaceDiagnosticReport;
8933 const METHOD: &'static str = "workspace/diagnostic";
8934}
8935pub struct DiagnosticRefreshRequest;
8936impl LspRequest for DiagnosticRefreshRequest {
8937 type Params = ();
8938 type Result = ();
8939 const METHOD: &'static str = "workspace/diagnostic/refresh";
8940}
8941pub struct InlineCompletionRequest;
8942impl LspRequest for InlineCompletionRequest {
8943 type Params = InlineCompletionParams;
8944 type Result = Option<InlineCompletionItemArrayOrInlineCompletionList>;
8945 const METHOD: &'static str = "textDocument/inlineCompletion";
8946}
8947pub struct TextDocumentContentRequest;
8948impl LspRequest for TextDocumentContentRequest {
8949 type Params = TextDocumentContentParams;
8950 type Result = TextDocumentContentResult;
8951 const METHOD: &'static str = "workspace/textDocumentContent";
8952}
8953pub struct TextDocumentContentRefreshRequest;
8954impl LspRequest for TextDocumentContentRefreshRequest {
8955 type Params = TextDocumentContentRefreshParams;
8956 type Result = ();
8957 const METHOD: &'static str = "workspace/textDocumentContent/refresh";
8958}
8959pub struct RegistrationRequest;
8960impl LspRequest for RegistrationRequest {
8961 type Params = RegistrationParams;
8962 type Result = ();
8963 const METHOD: &'static str = "client/registerCapability";
8964}
8965pub struct UnregistrationRequest;
8966impl LspRequest for UnregistrationRequest {
8967 type Params = UnregistrationParams;
8968 type Result = ();
8969 const METHOD: &'static str = "client/unregisterCapability";
8970}
8971pub struct InitializeRequest;
8972impl LspRequest for InitializeRequest {
8973 type Params = InitializeParams;
8974 type Result = InitializeResult;
8975 const METHOD: &'static str = "initialize";
8976}
8977pub struct ShutdownRequest;
8978impl LspRequest for ShutdownRequest {
8979 type Params = ();
8980 type Result = ();
8981 const METHOD: &'static str = "shutdown";
8982}
8983pub struct ShowMessageRequest;
8984impl LspRequest for ShowMessageRequest {
8985 type Params = ShowMessageRequestParams;
8986 type Result = Option<MessageActionItem>;
8987 const METHOD: &'static str = "window/showMessageRequest";
8988}
8989pub struct WillSaveTextDocumentWaitUntilRequest;
8990impl LspRequest for WillSaveTextDocumentWaitUntilRequest {
8991 type Params = WillSaveTextDocumentParams;
8992 type Result = Option<Vec<TextEdit>>;
8993 const METHOD: &'static str = "textDocument/willSaveWaitUntil";
8994}
8995pub struct CompletionRequest;
8996impl LspRequest for CompletionRequest {
8997 type Params = CompletionParams;
8998 type Result = Option<CompletionItemArrayOrCompletionList>;
8999 const METHOD: &'static str = "textDocument/completion";
9000}
9001pub struct CompletionResolveRequest;
9002impl LspRequest for CompletionResolveRequest {
9003 type Params = CompletionItem;
9004 type Result = CompletionItem;
9005 const METHOD: &'static str = "completionItem/resolve";
9006}
9007pub struct HoverRequest;
9008impl LspRequest for HoverRequest {
9009 type Params = HoverParams;
9010 type Result = Option<Hover>;
9011 const METHOD: &'static str = "textDocument/hover";
9012}
9013pub struct SignatureHelpRequest;
9014impl LspRequest for SignatureHelpRequest {
9015 type Params = SignatureHelpParams;
9016 type Result = Option<SignatureHelp>;
9017 const METHOD: &'static str = "textDocument/signatureHelp";
9018}
9019pub struct DefinitionRequest;
9020impl LspRequest for DefinitionRequest {
9021 type Params = DefinitionParams;
9022 type Result = Option<DefinitionOrDefinitionLinkArray>;
9023 const METHOD: &'static str = "textDocument/definition";
9024}
9025pub struct ReferencesRequest;
9026impl LspRequest for ReferencesRequest {
9027 type Params = ReferenceParams;
9028 type Result = Option<Vec<Location>>;
9029 const METHOD: &'static str = "textDocument/references";
9030}
9031pub struct DocumentHighlightRequest;
9032impl LspRequest for DocumentHighlightRequest {
9033 type Params = DocumentHighlightParams;
9034 type Result = Option<Vec<DocumentHighlight>>;
9035 const METHOD: &'static str = "textDocument/documentHighlight";
9036}
9037pub struct DocumentSymbolRequest;
9038impl LspRequest for DocumentSymbolRequest {
9039 type Params = DocumentSymbolParams;
9040 type Result = Option<DocumentSymbolArrayOrSymbolInformationArray>;
9041 const METHOD: &'static str = "textDocument/documentSymbol";
9042}
9043pub struct CodeActionRequest;
9044impl LspRequest for CodeActionRequest {
9045 type Params = CodeActionParams;
9046 type Result = Option<Vec<CodeActionOrCommand>>;
9047 const METHOD: &'static str = "textDocument/codeAction";
9048}
9049pub struct CodeActionResolveRequest;
9050impl LspRequest for CodeActionResolveRequest {
9051 type Params = CodeAction;
9052 type Result = CodeAction;
9053 const METHOD: &'static str = "codeAction/resolve";
9054}
9055pub struct WorkspaceSymbolRequest;
9056impl LspRequest for WorkspaceSymbolRequest {
9057 type Params = WorkspaceSymbolParams;
9058 type Result = Option<SymbolInformationArrayOrWorkspaceSymbolArray>;
9059 const METHOD: &'static str = "workspace/symbol";
9060}
9061pub struct WorkspaceSymbolResolveRequest;
9062impl LspRequest for WorkspaceSymbolResolveRequest {
9063 type Params = WorkspaceSymbol;
9064 type Result = WorkspaceSymbol;
9065 const METHOD: &'static str = "workspaceSymbol/resolve";
9066}
9067pub struct CodeLensRequest;
9068impl LspRequest for CodeLensRequest {
9069 type Params = CodeLensParams;
9070 type Result = Option<Vec<CodeLens>>;
9071 const METHOD: &'static str = "textDocument/codeLens";
9072}
9073pub struct CodeLensResolveRequest;
9074impl LspRequest for CodeLensResolveRequest {
9075 type Params = CodeLens;
9076 type Result = CodeLens;
9077 const METHOD: &'static str = "codeLens/resolve";
9078}
9079pub struct CodeLensRefreshRequest;
9080impl LspRequest for CodeLensRefreshRequest {
9081 type Params = ();
9082 type Result = ();
9083 const METHOD: &'static str = "workspace/codeLens/refresh";
9084}
9085pub struct DocumentLinkRequest;
9086impl LspRequest for DocumentLinkRequest {
9087 type Params = DocumentLinkParams;
9088 type Result = Option<Vec<DocumentLink>>;
9089 const METHOD: &'static str = "textDocument/documentLink";
9090}
9091pub struct DocumentLinkResolveRequest;
9092impl LspRequest for DocumentLinkResolveRequest {
9093 type Params = DocumentLink;
9094 type Result = DocumentLink;
9095 const METHOD: &'static str = "documentLink/resolve";
9096}
9097pub struct DocumentFormattingRequest;
9098impl LspRequest for DocumentFormattingRequest {
9099 type Params = DocumentFormattingParams;
9100 type Result = Option<Vec<TextEdit>>;
9101 const METHOD: &'static str = "textDocument/formatting";
9102}
9103pub struct DocumentRangeFormattingRequest;
9104impl LspRequest for DocumentRangeFormattingRequest {
9105 type Params = DocumentRangeFormattingParams;
9106 type Result = Option<Vec<TextEdit>>;
9107 const METHOD: &'static str = "textDocument/rangeFormatting";
9108}
9109pub struct DocumentRangesFormattingRequest;
9110impl LspRequest for DocumentRangesFormattingRequest {
9111 type Params = DocumentRangesFormattingParams;
9112 type Result = Option<Vec<TextEdit>>;
9113 const METHOD: &'static str = "textDocument/rangesFormatting";
9114}
9115pub struct DocumentOnTypeFormattingRequest;
9116impl LspRequest for DocumentOnTypeFormattingRequest {
9117 type Params = DocumentOnTypeFormattingParams;
9118 type Result = Option<Vec<TextEdit>>;
9119 const METHOD: &'static str = "textDocument/onTypeFormatting";
9120}
9121pub struct RenameRequest;
9122impl LspRequest for RenameRequest {
9123 type Params = RenameParams;
9124 type Result = Option<WorkspaceEdit>;
9125 const METHOD: &'static str = "textDocument/rename";
9126}
9127pub struct PrepareRenameRequest;
9128impl LspRequest for PrepareRenameRequest {
9129 type Params = PrepareRenameParams;
9130 type Result = Option<PrepareRenameResult>;
9131 const METHOD: &'static str = "textDocument/prepareRename";
9132}
9133pub struct ExecuteCommandRequest;
9134impl LspRequest for ExecuteCommandRequest {
9135 type Params = ExecuteCommandParams;
9136 type Result = Option<LSPAny>;
9137 const METHOD: &'static str = "workspace/executeCommand";
9138}
9139pub struct ApplyWorkspaceEditRequest;
9140impl LspRequest for ApplyWorkspaceEditRequest {
9141 type Params = ApplyWorkspaceEditParams;
9142 type Result = ApplyWorkspaceEditResult;
9143 const METHOD: &'static str = "workspace/applyEdit";
9144}
9145#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
9146pub enum KnownRequest {
9147 ImplementationRequest,
9148 TypeDefinitionRequest,
9149 WorkspaceFoldersRequest,
9150 ConfigurationRequest,
9151 DocumentColorRequest,
9152 ColorPresentationRequest,
9153 FoldingRangeRequest,
9154 FoldingRangeRefreshRequest,
9155 DeclarationRequest,
9156 SelectionRangeRequest,
9157 WorkDoneProgressCreateRequest,
9158 CallHierarchyPrepareRequest,
9159 CallHierarchyIncomingCallsRequest,
9160 CallHierarchyOutgoingCallsRequest,
9161 SemanticTokensRequest,
9162 SemanticTokensDeltaRequest,
9163 SemanticTokensRangeRequest,
9164 SemanticTokensRefreshRequest,
9165 ShowDocumentRequest,
9166 LinkedEditingRangeRequest,
9167 WillCreateFilesRequest,
9168 WillRenameFilesRequest,
9169 WillDeleteFilesRequest,
9170 MonikerRequest,
9171 TypeHierarchyPrepareRequest,
9172 TypeHierarchySupertypesRequest,
9173 TypeHierarchySubtypesRequest,
9174 InlineValueRequest,
9175 InlineValueRefreshRequest,
9176 InlayHintRequest,
9177 InlayHintResolveRequest,
9178 InlayHintRefreshRequest,
9179 DocumentDiagnosticRequest,
9180 WorkspaceDiagnosticRequest,
9181 DiagnosticRefreshRequest,
9182 InlineCompletionRequest,
9183 TextDocumentContentRequest,
9184 TextDocumentContentRefreshRequest,
9185 RegistrationRequest,
9186 UnregistrationRequest,
9187 InitializeRequest,
9188 ShutdownRequest,
9189 ShowMessageRequest,
9190 WillSaveTextDocumentWaitUntilRequest,
9191 CompletionRequest,
9192 CompletionResolveRequest,
9193 HoverRequest,
9194 SignatureHelpRequest,
9195 DefinitionRequest,
9196 ReferencesRequest,
9197 DocumentHighlightRequest,
9198 DocumentSymbolRequest,
9199 CodeActionRequest,
9200 CodeActionResolveRequest,
9201 WorkspaceSymbolRequest,
9202 WorkspaceSymbolResolveRequest,
9203 CodeLensRequest,
9204 CodeLensResolveRequest,
9205 CodeLensRefreshRequest,
9206 DocumentLinkRequest,
9207 DocumentLinkResolveRequest,
9208 DocumentFormattingRequest,
9209 DocumentRangeFormattingRequest,
9210 DocumentRangesFormattingRequest,
9211 DocumentOnTypeFormattingRequest,
9212 RenameRequest,
9213 PrepareRenameRequest,
9214 ExecuteCommandRequest,
9215 ApplyWorkspaceEditRequest,
9216}
9217pub trait LspNotification {
9218 type Params: Serialize + for<'de> Deserialize<'de>;
9219 const METHOD: &'static str;
9220}
9221pub struct DidChangeWorkspaceFoldersNotification;
9222impl LspNotification for DidChangeWorkspaceFoldersNotification {
9223 type Params = DidChangeWorkspaceFoldersParams;
9224 const METHOD: &'static str = "workspace/didChangeWorkspaceFolders";
9225}
9226pub struct WorkDoneProgressCancelNotification;
9227impl LspNotification for WorkDoneProgressCancelNotification {
9228 type Params = WorkDoneProgressCancelParams;
9229 const METHOD: &'static str = "window/workDoneProgress/cancel";
9230}
9231pub struct DidCreateFilesNotification;
9232impl LspNotification for DidCreateFilesNotification {
9233 type Params = CreateFilesParams;
9234 const METHOD: &'static str = "workspace/didCreateFiles";
9235}
9236pub struct DidRenameFilesNotification;
9237impl LspNotification for DidRenameFilesNotification {
9238 type Params = RenameFilesParams;
9239 const METHOD: &'static str = "workspace/didRenameFiles";
9240}
9241pub struct DidDeleteFilesNotification;
9242impl LspNotification for DidDeleteFilesNotification {
9243 type Params = DeleteFilesParams;
9244 const METHOD: &'static str = "workspace/didDeleteFiles";
9245}
9246pub struct DidOpenNotebookDocumentNotification;
9247impl LspNotification for DidOpenNotebookDocumentNotification {
9248 type Params = DidOpenNotebookDocumentParams;
9249 const METHOD: &'static str = "notebookDocument/didOpen";
9250}
9251pub struct DidChangeNotebookDocumentNotification;
9252impl LspNotification for DidChangeNotebookDocumentNotification {
9253 type Params = DidChangeNotebookDocumentParams;
9254 const METHOD: &'static str = "notebookDocument/didChange";
9255}
9256pub struct DidSaveNotebookDocumentNotification;
9257impl LspNotification for DidSaveNotebookDocumentNotification {
9258 type Params = DidSaveNotebookDocumentParams;
9259 const METHOD: &'static str = "notebookDocument/didSave";
9260}
9261pub struct DidCloseNotebookDocumentNotification;
9262impl LspNotification for DidCloseNotebookDocumentNotification {
9263 type Params = DidCloseNotebookDocumentParams;
9264 const METHOD: &'static str = "notebookDocument/didClose";
9265}
9266pub struct InitializedNotification;
9267impl LspNotification for InitializedNotification {
9268 type Params = InitializedParams;
9269 const METHOD: &'static str = "initialized";
9270}
9271pub struct ExitNotification;
9272impl LspNotification for ExitNotification {
9273 type Params = ();
9274 const METHOD: &'static str = "exit";
9275}
9276pub struct DidChangeConfigurationNotification;
9277impl LspNotification for DidChangeConfigurationNotification {
9278 type Params = DidChangeConfigurationParams;
9279 const METHOD: &'static str = "workspace/didChangeConfiguration";
9280}
9281pub struct ShowMessageNotification;
9282impl LspNotification for ShowMessageNotification {
9283 type Params = ShowMessageParams;
9284 const METHOD: &'static str = "window/showMessage";
9285}
9286pub struct LogMessageNotification;
9287impl LspNotification for LogMessageNotification {
9288 type Params = LogMessageParams;
9289 const METHOD: &'static str = "window/logMessage";
9290}
9291pub struct TelemetryEventNotification;
9292impl LspNotification for TelemetryEventNotification {
9293 type Params = LSPAny;
9294 const METHOD: &'static str = "telemetry/event";
9295}
9296pub struct DidOpenTextDocumentNotification;
9297impl LspNotification for DidOpenTextDocumentNotification {
9298 type Params = DidOpenTextDocumentParams;
9299 const METHOD: &'static str = "textDocument/didOpen";
9300}
9301pub struct DidChangeTextDocumentNotification;
9302impl LspNotification for DidChangeTextDocumentNotification {
9303 type Params = DidChangeTextDocumentParams;
9304 const METHOD: &'static str = "textDocument/didChange";
9305}
9306pub struct DidCloseTextDocumentNotification;
9307impl LspNotification for DidCloseTextDocumentNotification {
9308 type Params = DidCloseTextDocumentParams;
9309 const METHOD: &'static str = "textDocument/didClose";
9310}
9311pub struct DidSaveTextDocumentNotification;
9312impl LspNotification for DidSaveTextDocumentNotification {
9313 type Params = DidSaveTextDocumentParams;
9314 const METHOD: &'static str = "textDocument/didSave";
9315}
9316pub struct WillSaveTextDocumentNotification;
9317impl LspNotification for WillSaveTextDocumentNotification {
9318 type Params = WillSaveTextDocumentParams;
9319 const METHOD: &'static str = "textDocument/willSave";
9320}
9321pub struct DidChangeWatchedFilesNotification;
9322impl LspNotification for DidChangeWatchedFilesNotification {
9323 type Params = DidChangeWatchedFilesParams;
9324 const METHOD: &'static str = "workspace/didChangeWatchedFiles";
9325}
9326pub struct PublishDiagnosticsNotification;
9327impl LspNotification for PublishDiagnosticsNotification {
9328 type Params = PublishDiagnosticsParams;
9329 const METHOD: &'static str = "textDocument/publishDiagnostics";
9330}
9331pub struct SetTraceNotification;
9332impl LspNotification for SetTraceNotification {
9333 type Params = SetTraceParams;
9334 const METHOD: &'static str = "$/setTrace";
9335}
9336pub struct LogTraceNotification;
9337impl LspNotification for LogTraceNotification {
9338 type Params = LogTraceParams;
9339 const METHOD: &'static str = "$/logTrace";
9340}
9341pub struct CancelNotification;
9342impl LspNotification for CancelNotification {
9343 type Params = CancelParams;
9344 const METHOD: &'static str = "$/cancelRequest";
9345}
9346pub struct ProgressNotification;
9347impl LspNotification for ProgressNotification {
9348 type Params = ProgressParams;
9349 const METHOD: &'static str = "$/progress";
9350}