vscode-languageserver-protocol 3.17.0-next.2 → 3.17.0-next.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. package/lib/browser/main.js +1 -1
  2. package/lib/common/api.d.ts +31 -10
  3. package/lib/common/api.js +32 -7
  4. package/lib/common/connection.d.ts +45 -21
  5. package/lib/common/connection.js +1 -1
  6. package/lib/common/messages.js +0 -3
  7. package/lib/common/protocol.$.d.ts +8 -0
  8. package/lib/common/protocol.$.js +19 -0
  9. package/lib/common/protocol.callHierarchy.d.ts +1 -1
  10. package/lib/common/protocol.callHierarchy.js +1 -1
  11. package/lib/common/protocol.colorProvider.d.ts +1 -1
  12. package/lib/common/protocol.configuration.d.ts +5 -17
  13. package/lib/common/protocol.configuration.js +1 -0
  14. package/lib/common/protocol.d.ts +488 -70
  15. package/lib/common/protocol.declaration.d.ts +3 -3
  16. package/lib/common/protocol.declaration.js +2 -2
  17. package/lib/common/protocol.diagnostic.d.ts +364 -0
  18. package/lib/common/protocol.diagnostic.js +77 -0
  19. package/lib/common/protocol.fileOperations.d.ts +1 -1
  20. package/lib/common/protocol.foldingRange.d.ts +43 -27
  21. package/lib/common/protocol.foldingRange.js +1 -19
  22. package/lib/common/protocol.implementation.d.ts +3 -3
  23. package/lib/common/protocol.implementation.js +2 -2
  24. package/lib/common/protocol.inlayHint.d.ts +115 -0
  25. package/lib/common/protocol.inlayHint.js +44 -0
  26. package/lib/common/protocol.inlineValue.d.ts +91 -0
  27. package/lib/common/protocol.inlineValue.js +31 -0
  28. package/lib/common/protocol.js +137 -18
  29. package/lib/common/protocol.linkedEditingRange.d.ts +2 -2
  30. package/lib/common/protocol.moniker.d.ts +13 -11
  31. package/lib/common/protocol.moniker.js +8 -8
  32. package/lib/common/protocol.notebook.d.ts +402 -0
  33. package/lib/common/protocol.notebook.js +210 -0
  34. package/lib/common/protocol.progress.d.ts +2 -14
  35. package/lib/common/protocol.progress.js +4 -2
  36. package/lib/common/protocol.selectionRange.d.ts +2 -2
  37. package/lib/common/protocol.semanticTokens.d.ts +27 -2
  38. package/lib/common/protocol.typeDefinition.d.ts +2 -2
  39. package/lib/common/protocol.typeHierarchy.d.ts +89 -0
  40. package/lib/common/protocol.typeHierarchy.js +43 -0
  41. package/lib/common/{protocol.workspaceFolders.d.ts → protocol.workspaceFolder.d.ts} +11 -41
  42. package/lib/common/{protocol.workspaceFolders.js → protocol.workspaceFolder.js} +1 -1
  43. package/lib/node/main.js +1 -1
  44. package/metaModel.schema.json +705 -0
  45. package/package.json +4 -4
  46. package/lib/common/proposed.diagnostic.d.ts +0 -46
  47. package/lib/common/proposed.diagnostic.js +0 -23
@@ -0,0 +1,402 @@
1
+ import { URI, integer, DocumentUri, uinteger, LSPObject, TextDocumentItem, TextDocumentIdentifier, VersionedTextDocumentIdentifier } from 'vscode-languageserver-types';
2
+ import { ProtocolNotificationType, RegistrationType } from './messages';
3
+ import type { StaticRegistrationOptions, NotebookDocumentFilter, TextDocumentContentChangeEvent } from './protocol';
4
+ /**
5
+ * Notebook specific client capabilities.
6
+ *
7
+ * @since 3.17.0
8
+ * @proposed
9
+ */
10
+ export declare type NotebookDocumentSyncClientCapabilities = {
11
+ /**
12
+ * Whether implementation supports dynamic registration. If this is
13
+ * set to `true` the client supports the new
14
+ * `(TextDocumentRegistrationOptions & StaticRegistrationOptions)`
15
+ * return value for the corresponding server capability as well.
16
+ */
17
+ dynamicRegistration?: boolean;
18
+ /**
19
+ * The client supports sending execution summary data per cell.
20
+ */
21
+ executionSummarySupport?: boolean;
22
+ };
23
+ /**
24
+ * A notebook cell kind.
25
+ *
26
+ * @since 3.17.0
27
+ * @proposed
28
+ */
29
+ export declare namespace NotebookCellKind {
30
+ /**
31
+ * A markup-cell is formatted source that is used for display.
32
+ */
33
+ const Markup: 1;
34
+ /**
35
+ * A code-cell is source code.
36
+ */
37
+ const Code: 2;
38
+ function is(value: any): value is NotebookCellKind;
39
+ }
40
+ export declare type NotebookCellKind = 1 | 2;
41
+ export declare type ExecutionSummary = {
42
+ /**
43
+ * A strict monotonically increasing value
44
+ * indicating the execution order of a cell
45
+ * inside a notebook.
46
+ */
47
+ executionOrder: uinteger;
48
+ /**
49
+ * Whether the execution was successful or
50
+ * not if known by the client.
51
+ */
52
+ success?: boolean;
53
+ };
54
+ export declare namespace ExecutionSummary {
55
+ function create(executionOrder: number, success?: boolean): ExecutionSummary;
56
+ function is(value: any): value is ExecutionSummary;
57
+ function equals(one: ExecutionSummary | undefined, other: ExecutionSummary | undefined): boolean;
58
+ }
59
+ /**
60
+ * A notebook cell.
61
+ *
62
+ * A cell's document URI must be unique across ALL notebook
63
+ * cells and can therefore be used to uniquely identify a
64
+ * notebook cell or the cell's text document.
65
+ *
66
+ * @since 3.17.0
67
+ * @proposed
68
+ */
69
+ export declare type NotebookCell = {
70
+ /**
71
+ * The cell's kind
72
+ */
73
+ kind: NotebookCellKind;
74
+ /**
75
+ * The URI of the cell's text document
76
+ * content.
77
+ */
78
+ document: DocumentUri;
79
+ /**
80
+ * Additional metadata stored with the cell.
81
+ */
82
+ metadata?: LSPObject;
83
+ /**
84
+ * Additional execution summary information
85
+ * if supported by the client.
86
+ */
87
+ executionSummary?: ExecutionSummary;
88
+ };
89
+ export declare namespace NotebookCell {
90
+ function create(kind: NotebookCellKind, document: DocumentUri): NotebookCell;
91
+ function is(value: any): value is NotebookCell;
92
+ function diff(one: NotebookCell, two: NotebookCell): Set<keyof NotebookCell>;
93
+ }
94
+ /**
95
+ * A notebook document.
96
+ *
97
+ * @since 3.17.0
98
+ * @proposed
99
+ */
100
+ export declare type NotebookDocument = {
101
+ /**
102
+ * The notebook document's uri.
103
+ */
104
+ uri: URI;
105
+ /**
106
+ * The type of the notebook.
107
+ */
108
+ notebookType: string;
109
+ /**
110
+ * The version number of this document (it will increase after each
111
+ * change, including undo/redo).
112
+ */
113
+ version: integer;
114
+ /**
115
+ * Additional metadata stored with the notebook
116
+ * document.
117
+ */
118
+ metadata?: LSPObject;
119
+ /**
120
+ * The cells of a notebook.
121
+ */
122
+ cells: NotebookCell[];
123
+ };
124
+ export declare namespace NotebookDocument {
125
+ function create(uri: URI, notebookType: string, version: integer, cells: NotebookCell[]): NotebookDocument;
126
+ function is(value: any): value is NotebookDocument;
127
+ }
128
+ /**
129
+ * A literal to identify a notebook document in the client.
130
+ *
131
+ * @since 3.17.0
132
+ * @proposed
133
+ */
134
+ export declare type NotebookDocumentIdentifier = {
135
+ /**
136
+ * The notebook document's uri.
137
+ */
138
+ uri: URI;
139
+ };
140
+ /**
141
+ * A versioned notebook document identifier.
142
+ *
143
+ * @since 3.17.0
144
+ * @proposed
145
+ */
146
+ export declare type VersionedNotebookDocumentIdentifier = {
147
+ /**
148
+ * The version number of this notebook document.
149
+ */
150
+ version: integer;
151
+ /**
152
+ * The notebook document's uri.
153
+ */
154
+ uri: URI;
155
+ };
156
+ /**
157
+ * Options specific to a notebook plus its cells
158
+ * to be synced to the server.
159
+ *
160
+ * If a selector provide a notebook document
161
+ * filter but no cell selector all cells of a
162
+ * matching notebook document will be synced.
163
+ *
164
+ * If a selector provides no notebook document
165
+ * filter but only a cell selector all notebook
166
+ * document that contain at least one matching
167
+ * cell will be synced.
168
+ *
169
+ * @since 3.17.0
170
+ * @proposed
171
+ */
172
+ export declare type NotebookDocumentSyncOptions = {
173
+ /**
174
+ * The notebooks to be synced
175
+ */
176
+ notebookSelector: ({
177
+ /**
178
+ * The notebook to be synced If a string
179
+ * value is provided it matches against the
180
+ * notebook type. '*' matches every notebook.
181
+ */
182
+ notebook: string | NotebookDocumentFilter;
183
+ /**
184
+ * The cells of the matching notebook to be synced.
185
+ */
186
+ cells?: {
187
+ language: string;
188
+ }[];
189
+ } | {
190
+ /**
191
+ * The notebook to be synced If a string
192
+ * value is provided it matches against the
193
+ * notebook type. '*' matches every notebook.
194
+ */
195
+ notebook?: string | NotebookDocumentFilter;
196
+ /**
197
+ * The cells of the matching notebook to be synced.
198
+ */
199
+ cells: {
200
+ language: string;
201
+ }[];
202
+ })[];
203
+ /**
204
+ * Whether save notification should be forwarded to
205
+ * the server. Will only be honored if mode === `notebook`.
206
+ */
207
+ save?: boolean;
208
+ };
209
+ /**
210
+ * Registration options specific to a notebook.
211
+ *
212
+ * @since 3.17.0
213
+ * @proposed
214
+ */
215
+ export declare type NotebookDocumentSyncRegistrationOptions = NotebookDocumentSyncOptions & StaticRegistrationOptions;
216
+ export declare namespace NotebookDocumentSyncRegistrationType {
217
+ const method: 'notebookDocument/sync';
218
+ const type: RegistrationType<NotebookDocumentSyncRegistrationOptions>;
219
+ }
220
+ /**
221
+ * The params sent in a open notebook document notification.
222
+ *
223
+ * @since 3.17.0
224
+ * @proposed
225
+ */
226
+ export declare type DidOpenNotebookDocumentParams = {
227
+ /**
228
+ * The notebook document that got opened.
229
+ */
230
+ notebookDocument: NotebookDocument;
231
+ /**
232
+ * The text documents that represent the content
233
+ * of a notebook cell.
234
+ */
235
+ cellTextDocuments: TextDocumentItem[];
236
+ };
237
+ /**
238
+ * A notification sent when a notebook opens.
239
+ *
240
+ * @since 3.17.0
241
+ * @proposed
242
+ */
243
+ export declare namespace DidOpenNotebookDocumentNotification {
244
+ const method: 'notebookDocument/didOpen';
245
+ const type: ProtocolNotificationType<DidOpenNotebookDocumentParams, void>;
246
+ }
247
+ /**
248
+ * A change describing how to move a `NotebookCell`
249
+ * array from state S to S'.
250
+ *
251
+ * @since 3.17.0
252
+ * @proposed
253
+ */
254
+ export declare type NotebookCellArrayChange = {
255
+ /**
256
+ * The start oftest of the cell that changed.
257
+ */
258
+ start: uinteger;
259
+ /**
260
+ * The deleted cells
261
+ */
262
+ deleteCount: uinteger;
263
+ /**
264
+ * The new cells, if any
265
+ */
266
+ cells?: NotebookCell[];
267
+ };
268
+ export declare namespace NotebookCellArrayChange {
269
+ function is(value: any): value is NotebookCellArrayChange;
270
+ function create(start: uinteger, deleteCount: uinteger, cells?: NotebookCell[]): NotebookCellArrayChange;
271
+ }
272
+ /**
273
+ * A change event for a notebook document.
274
+ *
275
+ * @since 3.17.0
276
+ * @proposed
277
+ */
278
+ export declare type NotebookDocumentChangeEvent = {
279
+ /**
280
+ * The changed meta data if any.
281
+ */
282
+ metadata?: LSPObject;
283
+ /**
284
+ * Changes to cells
285
+ */
286
+ cells?: {
287
+ /**
288
+ * Changes to the cell structure to add or
289
+ * remove cells.
290
+ */
291
+ structure?: {
292
+ /**
293
+ * The change to the cell array.
294
+ */
295
+ array: NotebookCellArrayChange;
296
+ /**
297
+ * Additional opened cell text documents.
298
+ */
299
+ didOpen?: TextDocumentItem[];
300
+ /**
301
+ * Additional closed cell text documents.
302
+ */
303
+ didClose?: TextDocumentIdentifier[];
304
+ };
305
+ /**
306
+ * Changes to notebook cells properties like its
307
+ * kind, execution summary or metadata.
308
+ */
309
+ data?: NotebookCell[];
310
+ /**
311
+ * Changes to the text content of notebook cells.
312
+ */
313
+ textContent?: {
314
+ document: VersionedTextDocumentIdentifier;
315
+ changes: TextDocumentContentChangeEvent[];
316
+ }[];
317
+ };
318
+ };
319
+ /**
320
+ * The params sent in a change notebook document notification.
321
+ *
322
+ * @since 3.17.0
323
+ * @proposed
324
+ */
325
+ export declare type DidChangeNotebookDocumentParams = {
326
+ /**
327
+ * The notebook document that did change. The version number points
328
+ * to the version after all provided changes have been applied. If
329
+ * only the text document content of a cell changes the notebook version
330
+ * doesn't necessarily have to change.
331
+ */
332
+ notebookDocument: VersionedNotebookDocumentIdentifier;
333
+ /**
334
+ * The actual changes to the notebook document.
335
+ *
336
+ * The changes describe single state changes to the notebook document.
337
+ * So if there are two changes c1 (at array index 0) and c2 (at array
338
+ * index 1) for a notebook in state S then c1 moves the notebook from
339
+ * S to S' and c2 from S' to S''. So c1 is computed on the state S and
340
+ * c2 is computed on the state S'.
341
+ *
342
+ * To mirror the content of a notebook using change events use the following approach:
343
+ * - start with the same initial content
344
+ * - apply the 'notebookDocument/didChange' notifications in the order you receive them.
345
+ * - apply the `NotebookChangeEvent`s in a single notification in the order
346
+ * you receive them.
347
+ */
348
+ change: NotebookDocumentChangeEvent;
349
+ };
350
+ export declare namespace DidChangeNotebookDocumentNotification {
351
+ const method: 'notebookDocument/didChange';
352
+ const type: ProtocolNotificationType<DidChangeNotebookDocumentParams, void>;
353
+ }
354
+ /**
355
+ * The params sent in a save notebook document notification.
356
+ *
357
+ * @since 3.17.0
358
+ * @proposed
359
+ */
360
+ export declare type DidSaveNotebookDocumentParams = {
361
+ /**
362
+ * The notebook document that got saved.
363
+ */
364
+ notebookDocument: NotebookDocumentIdentifier;
365
+ };
366
+ /**
367
+ * A notification sent when a notebook document is saved.
368
+ *
369
+ * @since 3.17.0
370
+ * @proposed
371
+ */
372
+ export declare namespace DidSaveNotebookDocumentNotification {
373
+ const method: 'notebookDocument/didSave';
374
+ const type: ProtocolNotificationType<DidSaveNotebookDocumentParams, void>;
375
+ }
376
+ /**
377
+ * The params sent in a close notebook document notification.
378
+ *
379
+ * @since 3.17.0
380
+ * @proposed
381
+ */
382
+ export declare type DidCloseNotebookDocumentParams = {
383
+ /**
384
+ * The notebook document that got closed.
385
+ */
386
+ notebookDocument: NotebookDocumentIdentifier;
387
+ /**
388
+ * The text documents that represent the content
389
+ * of a notebook cell that got closed.
390
+ */
391
+ cellTextDocuments: TextDocumentIdentifier[];
392
+ };
393
+ /**
394
+ * A notification sent when a notebook closes.
395
+ *
396
+ * @since 3.17.0
397
+ * @proposed
398
+ */
399
+ export declare namespace DidCloseNotebookDocumentNotification {
400
+ const method: 'notebookDocument/didClose';
401
+ const type: ProtocolNotificationType<DidCloseNotebookDocumentParams, void>;
402
+ }
@@ -0,0 +1,210 @@
1
+ "use strict";
2
+ /* --------------------------------------------------------------------------------------------
3
+ * Copyright (c) Microsoft Corporation. All rights reserved.
4
+ * Licensed under the MIT License. See License.txt in the project root for license information.
5
+ * ------------------------------------------------------------------------------------------ */
6
+ Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.DidCloseNotebookDocumentNotification = exports.DidSaveNotebookDocumentNotification = exports.DidChangeNotebookDocumentNotification = exports.NotebookCellArrayChange = exports.DidOpenNotebookDocumentNotification = exports.NotebookDocumentSyncRegistrationType = exports.NotebookDocument = exports.NotebookCell = exports.ExecutionSummary = exports.NotebookCellKind = void 0;
8
+ const vscode_languageserver_types_1 = require("vscode-languageserver-types");
9
+ const Is = require("./utils/is");
10
+ const messages_1 = require("./messages");
11
+ /**
12
+ * A notebook cell kind.
13
+ *
14
+ * @since 3.17.0
15
+ * @proposed
16
+ */
17
+ var NotebookCellKind;
18
+ (function (NotebookCellKind) {
19
+ /**
20
+ * A markup-cell is formatted source that is used for display.
21
+ */
22
+ NotebookCellKind.Markup = 1;
23
+ /**
24
+ * A code-cell is source code.
25
+ */
26
+ NotebookCellKind.Code = 2;
27
+ function is(value) {
28
+ return value === 1 || value === 2;
29
+ }
30
+ NotebookCellKind.is = is;
31
+ })(NotebookCellKind = exports.NotebookCellKind || (exports.NotebookCellKind = {}));
32
+ var ExecutionSummary;
33
+ (function (ExecutionSummary) {
34
+ function create(executionOrder, success) {
35
+ const result = { executionOrder };
36
+ if (success === true || success === false) {
37
+ result.success = success;
38
+ }
39
+ return result;
40
+ }
41
+ ExecutionSummary.create = create;
42
+ function is(value) {
43
+ const candidate = value;
44
+ return Is.objectLiteral(candidate) && vscode_languageserver_types_1.uinteger.is(candidate.executionOrder) && (candidate.success === undefined || Is.boolean(candidate.success));
45
+ }
46
+ ExecutionSummary.is = is;
47
+ function equals(one, other) {
48
+ if (one === other) {
49
+ return true;
50
+ }
51
+ if (one === null || one === undefined || other === null || other === undefined) {
52
+ return false;
53
+ }
54
+ return one.executionOrder === other.executionOrder && one.success === other.success;
55
+ }
56
+ ExecutionSummary.equals = equals;
57
+ })(ExecutionSummary = exports.ExecutionSummary || (exports.ExecutionSummary = {}));
58
+ var NotebookCell;
59
+ (function (NotebookCell) {
60
+ function create(kind, document) {
61
+ return { kind, document };
62
+ }
63
+ NotebookCell.create = create;
64
+ function is(value) {
65
+ const candidate = value;
66
+ return Is.objectLiteral(candidate) && NotebookCellKind.is(candidate.kind) && vscode_languageserver_types_1.DocumentUri.is(candidate.document) &&
67
+ (candidate.metadata === undefined || Is.objectLiteral(candidate.metadata));
68
+ }
69
+ NotebookCell.is = is;
70
+ function diff(one, two) {
71
+ const result = new Set();
72
+ if (one.document !== two.document) {
73
+ result.add('document');
74
+ }
75
+ if (one.kind !== two.kind) {
76
+ result.add('kind');
77
+ }
78
+ if (one.executionSummary !== two.executionSummary) {
79
+ result.add('executionSummary');
80
+ }
81
+ if ((one.metadata !== undefined || two.metadata !== undefined) && !equalsMetadata(one.metadata, two.metadata)) {
82
+ result.add('metadata');
83
+ }
84
+ if ((one.executionSummary !== undefined || two.executionSummary !== undefined) && !ExecutionSummary.equals(one.executionSummary, two.executionSummary)) {
85
+ result.add('executionSummary');
86
+ }
87
+ return result;
88
+ }
89
+ NotebookCell.diff = diff;
90
+ function equalsMetadata(one, other) {
91
+ if (one === other) {
92
+ return true;
93
+ }
94
+ if (one === null || one === undefined || other === null || other === undefined) {
95
+ return false;
96
+ }
97
+ if (typeof one !== typeof other) {
98
+ return false;
99
+ }
100
+ if (typeof one !== 'object') {
101
+ return false;
102
+ }
103
+ const oneArray = Array.isArray(one);
104
+ const otherArray = Array.isArray(other);
105
+ if (oneArray !== otherArray) {
106
+ return false;
107
+ }
108
+ if (oneArray && otherArray) {
109
+ if (one.length !== other.length) {
110
+ return false;
111
+ }
112
+ for (let i = 0; i < one.length; i++) {
113
+ if (!equalsMetadata(one[i], other[i])) {
114
+ return false;
115
+ }
116
+ }
117
+ }
118
+ if (Is.objectLiteral(one) && Is.objectLiteral(other)) {
119
+ const oneKeys = Object.keys(one);
120
+ const otherKeys = Object.keys(other);
121
+ if (oneKeys.length !== otherKeys.length) {
122
+ return false;
123
+ }
124
+ oneKeys.sort();
125
+ otherKeys.sort();
126
+ if (!equalsMetadata(oneKeys, otherKeys)) {
127
+ return false;
128
+ }
129
+ for (let i = 0; i < oneKeys.length; i++) {
130
+ const prop = oneKeys[i];
131
+ if (!equalsMetadata(one[prop], other[prop])) {
132
+ return false;
133
+ }
134
+ }
135
+ }
136
+ return true;
137
+ }
138
+ })(NotebookCell = exports.NotebookCell || (exports.NotebookCell = {}));
139
+ var NotebookDocument;
140
+ (function (NotebookDocument) {
141
+ function create(uri, notebookType, version, cells) {
142
+ return { uri, notebookType, version, cells };
143
+ }
144
+ NotebookDocument.create = create;
145
+ function is(value) {
146
+ const candidate = value;
147
+ return Is.objectLiteral(candidate) && Is.string(candidate.uri) && vscode_languageserver_types_1.integer.is(candidate.version) && Is.typedArray(candidate.cells, NotebookCell.is);
148
+ }
149
+ NotebookDocument.is = is;
150
+ })(NotebookDocument = exports.NotebookDocument || (exports.NotebookDocument = {}));
151
+ var NotebookDocumentSyncRegistrationType;
152
+ (function (NotebookDocumentSyncRegistrationType) {
153
+ NotebookDocumentSyncRegistrationType.method = 'notebookDocument/sync';
154
+ NotebookDocumentSyncRegistrationType.type = new messages_1.RegistrationType(NotebookDocumentSyncRegistrationType.method);
155
+ })(NotebookDocumentSyncRegistrationType = exports.NotebookDocumentSyncRegistrationType || (exports.NotebookDocumentSyncRegistrationType = {}));
156
+ /**
157
+ * A notification sent when a notebook opens.
158
+ *
159
+ * @since 3.17.0
160
+ * @proposed
161
+ */
162
+ var DidOpenNotebookDocumentNotification;
163
+ (function (DidOpenNotebookDocumentNotification) {
164
+ DidOpenNotebookDocumentNotification.method = 'notebookDocument/didOpen';
165
+ DidOpenNotebookDocumentNotification.type = new messages_1.ProtocolNotificationType(DidOpenNotebookDocumentNotification.method);
166
+ })(DidOpenNotebookDocumentNotification = exports.DidOpenNotebookDocumentNotification || (exports.DidOpenNotebookDocumentNotification = {}));
167
+ var NotebookCellArrayChange;
168
+ (function (NotebookCellArrayChange) {
169
+ function is(value) {
170
+ const candidate = value;
171
+ return Is.objectLiteral(candidate) && vscode_languageserver_types_1.uinteger.is(candidate.start) && vscode_languageserver_types_1.uinteger.is(candidate.deleteCount) && (candidate.cells === undefined || Is.typedArray(candidate.cells, NotebookCell.is));
172
+ }
173
+ NotebookCellArrayChange.is = is;
174
+ function create(start, deleteCount, cells) {
175
+ const result = { start, deleteCount };
176
+ if (cells !== undefined) {
177
+ result.cells = cells;
178
+ }
179
+ return result;
180
+ }
181
+ NotebookCellArrayChange.create = create;
182
+ })(NotebookCellArrayChange = exports.NotebookCellArrayChange || (exports.NotebookCellArrayChange = {}));
183
+ var DidChangeNotebookDocumentNotification;
184
+ (function (DidChangeNotebookDocumentNotification) {
185
+ DidChangeNotebookDocumentNotification.method = 'notebookDocument/didChange';
186
+ DidChangeNotebookDocumentNotification.type = new messages_1.ProtocolNotificationType(DidChangeNotebookDocumentNotification.method);
187
+ })(DidChangeNotebookDocumentNotification = exports.DidChangeNotebookDocumentNotification || (exports.DidChangeNotebookDocumentNotification = {}));
188
+ /**
189
+ * A notification sent when a notebook document is saved.
190
+ *
191
+ * @since 3.17.0
192
+ * @proposed
193
+ */
194
+ var DidSaveNotebookDocumentNotification;
195
+ (function (DidSaveNotebookDocumentNotification) {
196
+ DidSaveNotebookDocumentNotification.method = 'notebookDocument/didSave';
197
+ DidSaveNotebookDocumentNotification.type = new messages_1.ProtocolNotificationType(DidSaveNotebookDocumentNotification.method);
198
+ })(DidSaveNotebookDocumentNotification = exports.DidSaveNotebookDocumentNotification || (exports.DidSaveNotebookDocumentNotification = {}));
199
+ /**
200
+ * A notification sent when a notebook closes.
201
+ *
202
+ * @since 3.17.0
203
+ * @proposed
204
+ */
205
+ var DidCloseNotebookDocumentNotification;
206
+ (function (DidCloseNotebookDocumentNotification) {
207
+ DidCloseNotebookDocumentNotification.method = 'notebookDocument/didClose';
208
+ DidCloseNotebookDocumentNotification.type = new messages_1.ProtocolNotificationType(DidCloseNotebookDocumentNotification.method);
209
+ })(DidCloseNotebookDocumentNotification = exports.DidCloseNotebookDocumentNotification || (exports.DidCloseNotebookDocumentNotification = {}));
210
+ //# sourceMappingURL=protocol.notebook.js.map
@@ -1,20 +1,6 @@
1
1
  import { NotificationHandler, RequestHandler, ProgressType, ProgressToken } from 'vscode-jsonrpc';
2
2
  import { uinteger } from 'vscode-languageserver-types';
3
3
  import { ProtocolRequestType, ProtocolNotificationType } from './messages';
4
- export interface WorkDoneProgressClientCapabilities {
5
- /**
6
- * Window specific client capabilities.
7
- */
8
- window?: {
9
- /**
10
- * Whether client supports server initiated progress using the
11
- * `window/workDoneProgress/create` request.
12
- *
13
- * Since 3.15.0
14
- */
15
- workDoneProgress?: boolean;
16
- };
17
- }
18
4
  export interface WorkDoneProgressBegin {
19
5
  kind: 'begin';
20
6
  /**
@@ -98,6 +84,7 @@ export interface WorkDoneProgressCreateParams {
98
84
  * reporting from the server.
99
85
  */
100
86
  export declare namespace WorkDoneProgressCreateRequest {
87
+ const method: 'window/workDoneProgress/create';
101
88
  const type: ProtocolRequestType<WorkDoneProgressCreateParams, void, never, void, void>;
102
89
  type HandlerSignature = RequestHandler<WorkDoneProgressCreateParams, void, void>;
103
90
  }
@@ -112,6 +99,7 @@ export interface WorkDoneProgressCancelParams {
112
99
  * initiated on the server side.
113
100
  */
114
101
  export declare namespace WorkDoneProgressCancelNotification {
102
+ const method: 'window/workDoneProgress/cancel';
115
103
  const type: ProtocolNotificationType<WorkDoneProgressCancelParams, void>;
116
104
  type HandlerSignature = NotificationHandler<WorkDoneProgressCancelParams>;
117
105
  }
@@ -21,7 +21,8 @@ var WorkDoneProgress;
21
21
  */
22
22
  var WorkDoneProgressCreateRequest;
23
23
  (function (WorkDoneProgressCreateRequest) {
24
- WorkDoneProgressCreateRequest.type = new messages_1.ProtocolRequestType('window/workDoneProgress/create');
24
+ WorkDoneProgressCreateRequest.method = 'window/workDoneProgress/create';
25
+ WorkDoneProgressCreateRequest.type = new messages_1.ProtocolRequestType(WorkDoneProgressCreateRequest.method);
25
26
  })(WorkDoneProgressCreateRequest = exports.WorkDoneProgressCreateRequest || (exports.WorkDoneProgressCreateRequest = {}));
26
27
  /**
27
28
  * The `window/workDoneProgress/cancel` notification is sent from the client to the server to cancel a progress
@@ -29,6 +30,7 @@ var WorkDoneProgressCreateRequest;
29
30
  */
30
31
  var WorkDoneProgressCancelNotification;
31
32
  (function (WorkDoneProgressCancelNotification) {
32
- WorkDoneProgressCancelNotification.type = new messages_1.ProtocolNotificationType('window/workDoneProgress/cancel');
33
+ WorkDoneProgressCancelNotification.method = 'window/workDoneProgress/cancel';
34
+ WorkDoneProgressCancelNotification.type = new messages_1.ProtocolNotificationType(WorkDoneProgressCancelNotification.method);
33
35
  })(WorkDoneProgressCancelNotification = exports.WorkDoneProgressCancelNotification || (exports.WorkDoneProgressCancelNotification = {}));
34
36
  //# sourceMappingURL=protocol.progress.js.map
@@ -1,7 +1,7 @@
1
1
  import { RequestHandler } from 'vscode-jsonrpc';
2
2
  import { TextDocumentIdentifier, Position, SelectionRange } from 'vscode-languageserver-types';
3
3
  import { ProtocolRequestType } from './messages';
4
- import { TextDocumentRegistrationOptions, WorkDoneProgressOptions, StaticRegistrationOptions, WorkDoneProgressParams, PartialResultParams } from './protocol';
4
+ import type { TextDocumentRegistrationOptions, WorkDoneProgressOptions, StaticRegistrationOptions, WorkDoneProgressParams, PartialResultParams } from './protocol';
5
5
  export interface SelectionRangeClientCapabilities {
6
6
  /**
7
7
  * Whether implementation supports dynamic registration for selection range providers. If this is set to `true`
@@ -35,6 +35,6 @@ export interface SelectionRangeParams extends WorkDoneProgressParams, PartialRes
35
35
  */
36
36
  export declare namespace SelectionRangeRequest {
37
37
  const method: 'textDocument/selectionRange';
38
- const type: ProtocolRequestType<SelectionRangeParams, SelectionRange[] | null, SelectionRange[], any, SelectionRangeRegistrationOptions>;
38
+ const type: ProtocolRequestType<SelectionRangeParams, SelectionRange[] | null, SelectionRange[], void, SelectionRangeRegistrationOptions>;
39
39
  type HandlerSignature = RequestHandler<SelectionRangeParams, SelectionRange[] | null, void>;
40
40
  }