1 |
|
2 |
|
3 |
|
4 |
|
5 | 'use strict';
|
6 | Object.defineProperty(exports, "__esModule", { value: true });
|
7 | exports.TypeHierarchyFeature = void 0;
|
8 | const vscode_languageserver_protocol_1 = require("vscode-languageserver-protocol");
|
9 | const TypeHierarchyFeature = (Base) => {
|
10 | return class extends Base {
|
11 | get typeHierarchy() {
|
12 | return {
|
13 | onPrepare: (handler) => {
|
14 | return this.connection.onRequest(vscode_languageserver_protocol_1.TypeHierarchyPrepareRequest.type, (params, cancel) => {
|
15 | return handler(params, cancel, this.attachWorkDoneProgress(params), undefined);
|
16 | });
|
17 | },
|
18 | onSupertypes: (handler) => {
|
19 | const type = vscode_languageserver_protocol_1.TypeHierarchySupertypesRequest.type;
|
20 | return this.connection.onRequest(type, (params, cancel) => {
|
21 | return handler(params, cancel, this.attachWorkDoneProgress(params), this.attachPartialResultProgress(type, params));
|
22 | });
|
23 | },
|
24 | onSubtypes: (handler) => {
|
25 | const type = vscode_languageserver_protocol_1.TypeHierarchySubtypesRequest.type;
|
26 | return this.connection.onRequest(type, (params, cancel) => {
|
27 | return handler(params, cancel, this.attachWorkDoneProgress(params), this.attachPartialResultProgress(type, params));
|
28 | });
|
29 | }
|
30 | };
|
31 | }
|
32 | };
|
33 | };
|
34 | exports.TypeHierarchyFeature = TypeHierarchyFeature;
|