1 import { RequestHandler } from 'vscode-jsonrpc';
2 import { Definition, DefinitionLink, LocationLink, Location } from 'vscode-languageserver-types';
3 import { ProtocolRequestType } from './messages';
4 import { TextDocumentRegistrationOptions, StaticRegistrationOptions, TextDocumentPositionParams, PartialResultParams, WorkDoneProgressParams, WorkDoneProgressOptions } from './protocol';
8 export interface TypeDefinitionClientCapabilities {
10 * Whether implementation supports dynamic registration. If this is set to `true`
11 * the client supports the new `TypeDefinitionRegistrationOptions` return value
12 * for the corresponding server capability as well.
14 dynamicRegistration?: boolean;
16 * The client supports additional metadata in the form of definition links.
20 linkSupport?: boolean;
22 export interface TypeDefinitionOptions extends WorkDoneProgressOptions {
24 export interface TypeDefinitionRegistrationOptions extends TextDocumentRegistrationOptions, TypeDefinitionOptions, StaticRegistrationOptions {
26 export interface TypeDefinitionParams extends TextDocumentPositionParams, WorkDoneProgressParams, PartialResultParams {
29 * A request to resolve the type definition locations of a symbol at a given text
30 * document position. The request's parameter is of type [TextDocumentPositioParams]
31 * (#TextDocumentPositionParams) the response is of type [Definition](#Definition) or a
32 * Thenable that resolves to such.
34 export declare namespace TypeDefinitionRequest {
35 const method: 'textDocument/typeDefinition';
36 const type: ProtocolRequestType<TypeDefinitionParams, Location | Location[] | LocationLink[] | null, Location[] | LocationLink[], void, TypeDefinitionRegistrationOptions>;
37 type HandlerSignature = RequestHandler<TypeDefinitionParams, Definition | DefinitionLink[] | null, void>;