UNPKG

vscode-debugprotocol

Version:

Npm module with declarations for the Visual Studio Code debug protocol

812 lines 121 kB
/** Declaration module describing the VS Code debug protocol. Auto-generated from json schema. Do not edit manually. */ export declare module DebugProtocol { /** Base class of requests, responses, and events. */ interface ProtocolMessage { /** Sequence number (also known as message ID). For protocol messages of type 'request' this ID can be used to cancel the request. */ seq: number; /** Message type. Values: 'request', 'response', 'event', etc. */ type: 'request' | 'response' | 'event' | string; } /** A client or debug adapter initiated request. */ interface Request extends ProtocolMessage { /** The command to execute. */ command: string; /** Object containing arguments for the command. */ arguments?: any; } /** A debug adapter initiated event. */ interface Event extends ProtocolMessage { /** Type of event. */ event: string; /** Event-specific information. */ body?: any; } /** Response for a request. */ interface Response extends ProtocolMessage { /** Sequence number of the corresponding request. */ request_seq: number; /** Outcome of the request. If true, the request was successful and the 'body' attribute may contain the result of the request. If the value is false, the attribute 'message' contains the error in short form and the 'body' may contain additional information (see 'ErrorResponse.body.error'). */ success: boolean; /** The command requested. */ command: string; /** Contains the raw error in short form if 'success' is false. This raw error might be interpreted by the frontend and is not shown in the UI. Some predefined values exist. Values: 'cancelled': request was cancelled. etc. */ message?: 'cancelled' | string; /** Contains request result if success is true and optional error details if success is false. */ body?: any; } /** On error (whenever 'success' is false), the body can provide more details. */ interface ErrorResponse extends Response { body: { /** An optional, structured error message. */ error?: Message; }; } /** Cancel request; value of command field is 'cancel'. The 'cancel' request is used by the frontend in two situations: - to indicate that it is no longer interested in the result produced by a specific request issued earlier - to cancel a progress sequence. Clients should only call this request if the capability 'supportsCancelRequest' is true. This request has a hint characteristic: a debug adapter can only be expected to make a 'best effort' in honouring this request but there are no guarantees. The 'cancel' request may return an error if it could not cancel an operation but a frontend should refrain from presenting this error to end users. A frontend client should only call this request if the capability 'supportsCancelRequest' is true. The request that got canceled still needs to send a response back. This can either be a normal result ('success' attribute true) or an error response ('success' attribute false and the 'message' set to 'cancelled'). Returning partial results from a cancelled request is possible but please note that a frontend client has no generic way for detecting that a response is partial or not. The progress that got cancelled still needs to send a 'progressEnd' event back. A client should not assume that progress just got cancelled after sending the 'cancel' request. */ interface CancelRequest extends Request { arguments?: CancelArguments; } /** Arguments for 'cancel' request. */ interface CancelArguments { /** The ID (attribute 'seq') of the request to cancel. If missing no request is cancelled. Both a 'requestId' and a 'progressId' can be specified in one request. */ requestId?: number; /** The ID (attribute 'progressId') of the progress to cancel. If missing no progress is cancelled. Both a 'requestId' and a 'progressId' can be specified in one request. */ progressId?: string; } /** Response to 'cancel' request. This is just an acknowledgement, so no body field is required. */ interface CancelResponse extends Response { } /** Event message for 'initialized' event type. This event indicates that the debug adapter is ready to accept configuration requests (e.g. SetBreakpointsRequest, SetExceptionBreakpointsRequest). A debug adapter is expected to send this event when it is ready to accept configuration requests (but not before the 'initialize' request has finished). The sequence of events/requests is as follows: - adapters sends 'initialized' event (after the 'initialize' request has returned) - frontend sends zero or more 'setBreakpoints' requests - frontend sends one 'setFunctionBreakpoints' request (if capability 'supportsFunctionBreakpoints' is true) - frontend sends a 'setExceptionBreakpoints' request if one or more 'exceptionBreakpointFilters' have been defined (or if 'supportsConfigurationDoneRequest' is not defined or false) - frontend sends other future configuration requests - frontend sends one 'configurationDone' request to indicate the end of the configuration. */ interface InitializedEvent extends Event { } /** Event message for 'stopped' event type. The event indicates that the execution of the debuggee has stopped due to some condition. This can be caused by a break point previously set, a stepping request has completed, by executing a debugger statement etc. */ interface StoppedEvent extends Event { body: { /** The reason for the event. For backward compatibility this string is shown in the UI if the 'description' attribute is missing (but it must not be translated). Values: 'step', 'breakpoint', 'exception', 'pause', 'entry', 'goto', 'function breakpoint', 'data breakpoint', 'instruction breakpoint', etc. */ reason: 'step' | 'breakpoint' | 'exception' | 'pause' | 'entry' | 'goto' | 'function breakpoint' | 'data breakpoint' | 'instruction breakpoint' | string; /** The full reason for the event, e.g. 'Paused on exception'. This string is shown in the UI as is and must be translated. */ description?: string; /** The thread which was stopped. */ threadId?: number; /** A value of true hints to the frontend that this event should not change the focus. */ preserveFocusHint?: boolean; /** Additional information. E.g. if reason is 'exception', text contains the exception name. This string is shown in the UI. */ text?: string; /** If 'allThreadsStopped' is true, a debug adapter can announce that all threads have stopped. - The client should use this information to enable that all threads can be expanded to access their stacktraces. - If the attribute is missing or false, only the thread with the given threadId can be expanded. */ allThreadsStopped?: boolean; /** Ids of the breakpoints that triggered the event. In most cases there will be only a single breakpoint but here are some examples for multiple breakpoints: - Different types of breakpoints map to the same location. - Multiple source breakpoints get collapsed to the same instruction by the compiler/runtime. - Multiple function breakpoints with different function names map to the same location. */ hitBreakpointIds?: number[]; }; } /** Event message for 'continued' event type. The event indicates that the execution of the debuggee has continued. Please note: a debug adapter is not expected to send this event in response to a request that implies that execution continues, e.g. 'launch' or 'continue'. It is only necessary to send a 'continued' event if there was no previous request that implied this. */ interface ContinuedEvent extends Event { body: { /** The thread which was continued. */ threadId: number; /** If 'allThreadsContinued' is true, a debug adapter can announce that all threads have continued. */ allThreadsContinued?: boolean; }; } /** Event message for 'exited' event type. The event indicates that the debuggee has exited and returns its exit code. */ interface ExitedEvent extends Event { body: { /** The exit code returned from the debuggee. */ exitCode: number; }; } /** Event message for 'terminated' event type. The event indicates that debugging of the debuggee has terminated. This does **not** mean that the debuggee itself has exited. */ interface TerminatedEvent extends Event { body?: { /** A debug adapter may set 'restart' to true (or to an arbitrary object) to request that the front end restarts the session. The value is not interpreted by the client and passed unmodified as an attribute '__restart' to the 'launch' and 'attach' requests. */ restart?: any; }; } /** Event message for 'thread' event type. The event indicates that a thread has started or exited. */ interface ThreadEvent extends Event { body: { /** The reason for the event. Values: 'started', 'exited', etc. */ reason: 'started' | 'exited' | string; /** The identifier of the thread. */ threadId: number; }; } /** Event message for 'output' event type. The event indicates that the target has produced some output. */ interface OutputEvent extends Event { body: { /** The output category. If not specified or if the category is not understand by the client, 'console' is assumed. Values: 'console': Show the output in the client's default message UI, e.g. a 'debug console'. This category should only be used for informational output from the debugger (as opposed to the debuggee). 'important': A hint for the client to show the ouput in the client's UI for important and highly visible information, e.g. as a popup notification. This category should only be used for important messages from the debugger (as opposed to the debuggee). Since this category value is a hint, clients might ignore the hint and assume the 'console' category. 'stdout': Show the output as normal program output from the debuggee. 'stderr': Show the output as error program output from the debuggee. 'telemetry': Send the output to telemetry instead of showing it to the user. etc. */ category?: 'console' | 'important' | 'stdout' | 'stderr' | 'telemetry' | string; /** The output to report. */ output: string; /** Support for keeping an output log organized by grouping related messages. 'start': Start a new group in expanded mode. Subsequent output events are members of the group and should be shown indented. The 'output' attribute becomes the name of the group and is not indented. 'startCollapsed': Start a new group in collapsed mode. Subsequent output events are members of the group and should be shown indented (as soon as the group is expanded). The 'output' attribute becomes the name of the group and is not indented. 'end': End the current group and decreases the indentation of subsequent output events. A non empty 'output' attribute is shown as the unindented end of the group. */ group?: 'start' | 'startCollapsed' | 'end'; /** If an attribute 'variablesReference' exists and its value is > 0, the output contains objects which can be retrieved by passing 'variablesReference' to the 'variables' request. The value should be less than or equal to 2147483647 (2^31-1). */ variablesReference?: number; /** An optional source location where the output was produced. */ source?: Source; /** An optional source location line where the output was produced. */ line?: number; /** An optional source location column where the output was produced. */ column?: number; /** Optional data to report. For the 'telemetry' category the data will be sent to telemetry, for the other categories the data is shown in JSON format. */ data?: any; }; } /** Event message for 'breakpoint' event type. The event indicates that some information about a breakpoint has changed. */ interface BreakpointEvent extends Event { body: { /** The reason for the event. Values: 'changed', 'new', 'removed', etc. */ reason: 'changed' | 'new' | 'removed' | string; /** The 'id' attribute is used to find the target breakpoint and the other attributes are used as the new values. */ breakpoint: Breakpoint; }; } /** Event message for 'module' event type. The event indicates that some information about a module has changed. */ interface ModuleEvent extends Event { body: { /** The reason for the event. */ reason: 'new' | 'changed' | 'removed'; /** The new, changed, or removed module. In case of 'removed' only the module id is used. */ module: Module; }; } /** Event message for 'loadedSource' event type. The event indicates that some source has been added, changed, or removed from the set of all loaded sources. */ interface LoadedSourceEvent extends Event { body: { /** The reason for the event. */ reason: 'new' | 'changed' | 'removed'; /** The new, changed, or removed source. */ source: Source; }; } /** Event message for 'process' event type. The event indicates that the debugger has begun debugging a new process. Either one that it has launched, or one that it has attached to. */ interface ProcessEvent extends Event { body: { /** The logical name of the process. This is usually the full path to process's executable file. Example: /home/example/myproj/program.js. */ name: string; /** The system process id of the debugged process. This property will be missing for non-system processes. */ systemProcessId?: number; /** If true, the process is running on the same computer as the debug adapter. */ isLocalProcess?: boolean; /** Describes how the debug engine started debugging this process. 'launch': Process was launched under the debugger. 'attach': Debugger attached to an existing process. 'attachForSuspendedLaunch': A project launcher component has launched a new process in a suspended state and then asked the debugger to attach. */ startMethod?: 'launch' | 'attach' | 'attachForSuspendedLaunch'; /** The size of a pointer or address for this process, in bits. This value may be used by clients when formatting addresses for display. */ pointerSize?: number; }; } /** Event message for 'capabilities' event type. The event indicates that one or more capabilities have changed. Since the capabilities are dependent on the frontend and its UI, it might not be possible to change that at random times (or too late). Consequently this event has a hint characteristic: a frontend can only be expected to make a 'best effort' in honouring individual capabilities but there are no guarantees. Only changed capabilities need to be included, all other capabilities keep their values. */ interface CapabilitiesEvent extends Event { body: { /** The set of updated capabilities. */ capabilities: Capabilities; }; } /** Event message for 'progressStart' event type. The event signals that a long running operation is about to start and provides additional information for the client to set up a corresponding progress and cancellation UI. The client is free to delay the showing of the UI in order to reduce flicker. This event should only be sent if the client has passed the value true for the 'supportsProgressReporting' capability of the 'initialize' request. */ interface ProgressStartEvent extends Event { body: { /** An ID that must be used in subsequent 'progressUpdate' and 'progressEnd' events to make them refer to the same progress reporting. IDs must be unique within a debug session. */ progressId: string; /** Mandatory (short) title of the progress reporting. Shown in the UI to describe the long running operation. */ title: string; /** The request ID that this progress report is related to. If specified a debug adapter is expected to emit progress events for the long running request until the request has been either completed or cancelled. If the request ID is omitted, the progress report is assumed to be related to some general activity of the debug adapter. */ requestId?: number; /** If true, the request that reports progress may be canceled with a 'cancel' request. So this property basically controls whether the client should use UX that supports cancellation. Clients that don't support cancellation are allowed to ignore the setting. */ cancellable?: boolean; /** Optional, more detailed progress message. */ message?: string; /** Optional progress percentage to display (value range: 0 to 100). If omitted no percentage will be shown. */ percentage?: number; }; } /** Event message for 'progressUpdate' event type. The event signals that the progress reporting needs to updated with a new message and/or percentage. The client does not have to update the UI immediately, but the clients needs to keep track of the message and/or percentage values. This event should only be sent if the client has passed the value true for the 'supportsProgressReporting' capability of the 'initialize' request. */ interface ProgressUpdateEvent extends Event { body: { /** The ID that was introduced in the initial 'progressStart' event. */ progressId: string; /** Optional, more detailed progress message. If omitted, the previous message (if any) is used. */ message?: string; /** Optional progress percentage to display (value range: 0 to 100). If omitted no percentage will be shown. */ percentage?: number; }; } /** Event message for 'progressEnd' event type. The event signals the end of the progress reporting with an optional final message. This event should only be sent if the client has passed the value true for the 'supportsProgressReporting' capability of the 'initialize' request. */ interface ProgressEndEvent extends Event { body: { /** The ID that was introduced in the initial 'ProgressStartEvent'. */ progressId: string; /** Optional, more detailed progress message. If omitted, the previous message (if any) is used. */ message?: string; }; } /** Event message for 'invalidated' event type. This event signals that some state in the debug adapter has changed and requires that the client needs to re-render the data snapshot previously requested. Debug adapters do not have to emit this event for runtime changes like stopped or thread events because in that case the client refetches the new state anyway. But the event can be used for example to refresh the UI after rendering formatting has changed in the debug adapter. This event should only be sent if the debug adapter has received a value true for the 'supportsInvalidatedEvent' capability of the 'initialize' request. */ interface InvalidatedEvent extends Event { body: { /** Optional set of logical areas that got invalidated. This property has a hint characteristic: a client can only be expected to make a 'best effort' in honouring the areas but there are no guarantees. If this property is missing, empty, or if values are not understand the client should assume a single value 'all'. */ areas?: InvalidatedAreas[]; /** If specified, the client only needs to refetch data related to this thread. */ threadId?: number; /** If specified, the client only needs to refetch data related to this stack frame (and the 'threadId' is ignored). */ stackFrameId?: number; }; } /** Event message for 'memory' event type. This event indicates that some memory range has been updated. It should only be sent if the debug adapter has received a value true for the `supportsMemoryEvent` capability of the `initialize` request. Clients typically react to the event by re-issuing a `readMemory` request if they show the memory identified by the `memoryReference` and if the updated memory range overlaps the displayed range. Clients should not make assumptions how individual memory references relate to each other, so they should not assume that they are part of a single continuous address range and might overlap. Debug adapters can use this event to indicate that the contents of a memory range has changed due to some other DAP request like `setVariable` or `setExpression`. Debug adapters are not expected to emit this event for each and every memory change of a running program, because that information is typically not available from debuggers and it would flood clients with too many events. */ interface MemoryEvent extends Event { body: { /** Memory reference of a memory range that has been updated. */ memoryReference: string; /** Starting offset in bytes where memory has been updated. Can be negative. */ offset: number; /** Number of bytes updated. */ count: number; }; } /** RunInTerminal request; value of command field is 'runInTerminal'. This optional request is sent from the debug adapter to the client to run a command in a terminal. This is typically used to launch the debuggee in a terminal provided by the client. This request should only be called if the client has passed the value true for the 'supportsRunInTerminalRequest' capability of the 'initialize' request. */ interface RunInTerminalRequest extends Request { arguments: RunInTerminalRequestArguments; } /** Arguments for 'runInTerminal' request. */ interface RunInTerminalRequestArguments { /** What kind of terminal to launch. */ kind?: 'integrated' | 'external'; /** Optional title of the terminal. */ title?: string; /** Working directory for the command. For non-empty, valid paths this typically results in execution of a change directory command. */ cwd: string; /** List of arguments. The first argument is the command to run. */ args: string[]; /** Environment key-value pairs that are added to or removed from the default environment. */ env?: { [key: string]: string | null; }; } /** Response to 'runInTerminal' request. */ interface RunInTerminalResponse extends Response { body: { /** The process ID. The value should be less than or equal to 2147483647 (2^31-1). */ processId?: number; /** The process ID of the terminal shell. The value should be less than or equal to 2147483647 (2^31-1). */ shellProcessId?: number; }; } /** Initialize request; value of command field is 'initialize'. The 'initialize' request is sent as the first request from the client to the debug adapter in order to configure it with client capabilities and to retrieve capabilities from the debug adapter. Until the debug adapter has responded to with an 'initialize' response, the client must not send any additional requests or events to the debug adapter. In addition the debug adapter is not allowed to send any requests or events to the client until it has responded with an 'initialize' response. The 'initialize' request may only be sent once. */ interface InitializeRequest extends Request { arguments: InitializeRequestArguments; } /** Arguments for 'initialize' request. */ interface InitializeRequestArguments { /** The ID of the (frontend) client using this adapter. */ clientID?: string; /** The human readable name of the (frontend) client using this adapter. */ clientName?: string; /** The ID of the debug adapter. */ adapterID: string; /** The ISO-639 locale of the (frontend) client using this adapter, e.g. en-US or de-CH. */ locale?: string; /** If true all line numbers are 1-based (default). */ linesStartAt1?: boolean; /** If true all column numbers are 1-based (default). */ columnsStartAt1?: boolean; /** Determines in what format paths are specified. The default is 'path', which is the native format. Values: 'path', 'uri', etc. */ pathFormat?: 'path' | 'uri' | string; /** Client supports the optional type attribute for variables. */ supportsVariableType?: boolean; /** Client supports the paging of variables. */ supportsVariablePaging?: boolean; /** Client supports the runInTerminal request. */ supportsRunInTerminalRequest?: boolean; /** Client supports memory references. */ supportsMemoryReferences?: boolean; /** Client supports progress reporting. */ supportsProgressReporting?: boolean; /** Client supports the invalidated event. */ supportsInvalidatedEvent?: boolean; /** Client supports the memory event. */ supportsMemoryEvent?: boolean; } /** Response to 'initialize' request. */ interface InitializeResponse extends Response { /** The capabilities of this debug adapter. */ body?: Capabilities; } /** ConfigurationDone request; value of command field is 'configurationDone'. This optional request indicates that the client has finished initialization of the debug adapter. So it is the last request in the sequence of configuration requests (which was started by the 'initialized' event). Clients should only call this request if the capability 'supportsConfigurationDoneRequest' is true. */ interface ConfigurationDoneRequest extends Request { arguments?: ConfigurationDoneArguments; } /** Arguments for 'configurationDone' request. */ interface ConfigurationDoneArguments { } /** Response to 'configurationDone' request. This is just an acknowledgement, so no body field is required. */ interface ConfigurationDoneResponse extends Response { } /** Launch request; value of command field is 'launch'. This launch request is sent from the client to the debug adapter to start the debuggee with or without debugging (if 'noDebug' is true). Since launching is debugger/runtime specific, the arguments for this request are not part of this specification. */ interface LaunchRequest extends Request { arguments: LaunchRequestArguments; } /** Arguments for 'launch' request. Additional attributes are implementation specific. */ interface LaunchRequestArguments { /** If noDebug is true the launch request should launch the program without enabling debugging. */ noDebug?: boolean; /** Optional data from the previous, restarted session. The data is sent as the 'restart' attribute of the 'terminated' event. The client should leave the data intact. */ __restart?: any; } /** Response to 'launch' request. This is just an acknowledgement, so no body field is required. */ interface LaunchResponse extends Response { } /** Attach request; value of command field is 'attach'. The attach request is sent from the client to the debug adapter to attach to a debuggee that is already running. Since attaching is debugger/runtime specific, the arguments for this request are not part of this specification. */ interface AttachRequest extends Request { arguments: AttachRequestArguments; } /** Arguments for 'attach' request. Additional attributes are implementation specific. */ interface AttachRequestArguments { /** Optional data from the previous, restarted session. The data is sent as the 'restart' attribute of the 'terminated' event. The client should leave the data intact. */ __restart?: any; } /** Response to 'attach' request. This is just an acknowledgement, so no body field is required. */ interface AttachResponse extends Response { } /** Restart request; value of command field is 'restart'. Restarts a debug session. Clients should only call this request if the capability 'supportsRestartRequest' is true. If the capability is missing or has the value false, a typical client will emulate 'restart' by terminating the debug adapter first and then launching it anew. */ interface RestartRequest extends Request { arguments?: RestartArguments; } /** Arguments for 'restart' request. */ interface RestartArguments { /** The latest version of the 'launch' or 'attach' configuration. */ arguments?: LaunchRequestArguments | AttachRequestArguments; } /** Response to 'restart' request. This is just an acknowledgement, so no body field is required. */ interface RestartResponse extends Response { } /** Disconnect request; value of command field is 'disconnect'. The 'disconnect' request is sent from the client to the debug adapter in order to stop debugging. It asks the debug adapter to disconnect from the debuggee and to terminate the debug adapter. If the debuggee has been started with the 'launch' request, the 'disconnect' request terminates the debuggee. If the 'attach' request was used to connect to the debuggee, 'disconnect' does not terminate the debuggee. This behavior can be controlled with the 'terminateDebuggee' argument (if supported by the debug adapter). */ interface DisconnectRequest extends Request { arguments?: DisconnectArguments; } /** Arguments for 'disconnect' request. */ interface DisconnectArguments { /** A value of true indicates that this 'disconnect' request is part of a restart sequence. */ restart?: boolean; /** Indicates whether the debuggee should be terminated when the debugger is disconnected. If unspecified, the debug adapter is free to do whatever it thinks is best. The attribute is only honored by a debug adapter if the capability 'supportTerminateDebuggee' is true. */ terminateDebuggee?: boolean; /** Indicates whether the debuggee should stay suspended when the debugger is disconnected. If unspecified, the debuggee should resume execution. The attribute is only honored by a debug adapter if the capability 'supportSuspendDebuggee' is true. */ suspendDebuggee?: boolean; } /** Response to 'disconnect' request. This is just an acknowledgement, so no body field is required. */ interface DisconnectResponse extends Response { } /** Terminate request; value of command field is 'terminate'. The 'terminate' request is sent from the client to the debug adapter in order to give the debuggee a chance for terminating itself. Clients should only call this request if the capability 'supportsTerminateRequest' is true. */ interface TerminateRequest extends Request { arguments?: TerminateArguments; } /** Arguments for 'terminate' request. */ interface TerminateArguments { /** A value of true indicates that this 'terminate' request is part of a restart sequence. */ restart?: boolean; } /** Response to 'terminate' request. This is just an acknowledgement, so no body field is required. */ interface TerminateResponse extends Response { } /** BreakpointLocations request; value of command field is 'breakpointLocations'. The 'breakpointLocations' request returns all possible locations for source breakpoints in a given range. Clients should only call this request if the capability 'supportsBreakpointLocationsRequest' is true. */ interface BreakpointLocationsRequest extends Request { arguments?: BreakpointLocationsArguments; } /** Arguments for 'breakpointLocations' request. */ interface BreakpointLocationsArguments { /** The source location of the breakpoints; either 'source.path' or 'source.reference' must be specified. */ source: Source; /** Start line of range to search possible breakpoint locations in. If only the line is specified, the request returns all possible locations in that line. */ line: number; /** Optional start column of range to search possible breakpoint locations in. If no start column is given, the first column in the start line is assumed. */ column?: number; /** Optional end line of range to search possible breakpoint locations in. If no end line is given, then the end line is assumed to be the start line. */ endLine?: number; /** Optional end column of range to search possible breakpoint locations in. If no end column is given, then it is assumed to be in the last column of the end line. */ endColumn?: number; } /** Response to 'breakpointLocations' request. Contains possible locations for source breakpoints. */ interface BreakpointLocationsResponse extends Response { body: { /** Sorted set of possible breakpoint locations. */ breakpoints: BreakpointLocation[]; }; } /** SetBreakpoints request; value of command field is 'setBreakpoints'. Sets multiple breakpoints for a single source and clears all previous breakpoints in that source. To clear all breakpoint for a source, specify an empty array. When a breakpoint is hit, a 'stopped' event (with reason 'breakpoint') is generated. */ interface SetBreakpointsRequest extends Request { arguments: SetBreakpointsArguments; } /** Arguments for 'setBreakpoints' request. */ interface SetBreakpointsArguments { /** The source location of the breakpoints; either 'source.path' or 'source.reference' must be specified. */ source: Source; /** The code locations of the breakpoints. */ breakpoints?: SourceBreakpoint[]; /** Deprecated: The code locations of the breakpoints. */ lines?: number[]; /** A value of true indicates that the underlying source has been modified which results in new breakpoint locations. */ sourceModified?: boolean; } /** Response to 'setBreakpoints' request. Returned is information about each breakpoint created by this request. This includes the actual code location and whether the breakpoint could be verified. The breakpoints returned are in the same order as the elements of the 'breakpoints' (or the deprecated 'lines') array in the arguments. */ interface SetBreakpointsResponse extends Response { body: { /** Information about the breakpoints. The array elements are in the same order as the elements of the 'breakpoints' (or the deprecated 'lines') array in the arguments. */ breakpoints: Breakpoint[]; }; } /** SetFunctionBreakpoints request; value of command field is 'setFunctionBreakpoints'. Replaces all existing function breakpoints with new function breakpoints. To clear all function breakpoints, specify an empty array. When a function breakpoint is hit, a 'stopped' event (with reason 'function breakpoint') is generated. Clients should only call this request if the capability 'supportsFunctionBreakpoints' is true. */ interface SetFunctionBreakpointsRequest extends Request { arguments: SetFunctionBreakpointsArguments; } /** Arguments for 'setFunctionBreakpoints' request. */ interface SetFunctionBreakpointsArguments { /** The function names of the breakpoints. */ breakpoints: FunctionBreakpoint[]; } /** Response to 'setFunctionBreakpoints' request. Returned is information about each breakpoint created by this request. */ interface SetFunctionBreakpointsResponse extends Response { body: { /** Information about the breakpoints. The array elements correspond to the elements of the 'breakpoints' array. */ breakpoints: Breakpoint[]; }; } /** SetExceptionBreakpoints request; value of command field is 'setExceptionBreakpoints'. The request configures the debuggers response to thrown exceptions. If an exception is configured to break, a 'stopped' event is fired (with reason 'exception'). Clients should only call this request if the capability 'exceptionBreakpointFilters' returns one or more filters. */ interface SetExceptionBreakpointsRequest extends Request { arguments: SetExceptionBreakpointsArguments; } /** Arguments for 'setExceptionBreakpoints' request. */ interface SetExceptionBreakpointsArguments { /** Set of exception filters specified by their ID. The set of all possible exception filters is defined by the 'exceptionBreakpointFilters' capability. The 'filter' and 'filterOptions' sets are additive. */ filters: string[]; /** Set of exception filters and their options. The set of all possible exception filters is defined by the 'exceptionBreakpointFilters' capability. This attribute is only honored by a debug adapter if the capability 'supportsExceptionFilterOptions' is true. The 'filter' and 'filterOptions' sets are additive. */ filterOptions?: ExceptionFilterOptions[]; /** Configuration options for selected exceptions. The attribute is only honored by a debug adapter if the capability 'supportsExceptionOptions' is true. */ exceptionOptions?: ExceptionOptions[]; } /** Response to 'setExceptionBreakpoints' request. The response contains an array of Breakpoint objects with information about each exception breakpoint or filter. The Breakpoint objects are in the same order as the elements of the 'filters', 'filterOptions', 'exceptionOptions' arrays given as arguments. If both 'filters' and 'filterOptions' are given, the returned array must start with 'filters' information first, followed by 'filterOptions' information. The mandatory 'verified' property of a Breakpoint object signals whether the exception breakpoint or filter could be successfully created and whether the optional condition or hit count expressions are valid. In case of an error the 'message' property explains the problem. An optional 'id' property can be used to introduce a unique ID for the exception breakpoint or filter so that it can be updated subsequently by sending breakpoint events. For backward compatibility both the 'breakpoints' array and the enclosing 'body' are optional. If these elements are missing a client will not be able to show problems for individual exception breakpoints or filters. */ interface SetExceptionBreakpointsResponse extends Response { body?: { /** Information about the exception breakpoints or filters. The breakpoints returned are in the same order as the elements of the 'filters', 'filterOptions', 'exceptionOptions' arrays in the arguments. If both 'filters' and 'filterOptions' are given, the returned array must start with 'filters' information first, followed by 'filterOptions' information. */ breakpoints?: Breakpoint[]; }; } /** DataBreakpointInfo request; value of command field is 'dataBreakpointInfo'. Obtains information on a possible data breakpoint that could be set on an expression or variable. Clients should only call this request if the capability 'supportsDataBreakpoints' is true. */ interface DataBreakpointInfoRequest extends Request { arguments: DataBreakpointInfoArguments; } /** Arguments for 'dataBreakpointInfo' request. */ interface DataBreakpointInfoArguments { /** Reference to the Variable container if the data breakpoint is requested for a child of the container. */ variablesReference?: number; /** The name of the Variable's child to obtain data breakpoint information for. If variablesReference isn't provided, this can be an expression. */ name: string; } /** Response to 'dataBreakpointInfo' request. */ interface DataBreakpointInfoResponse extends Response { body: { /** An identifier for the data on which a data breakpoint can be registered with the setDataBreakpoints request or null if no data breakpoint is available. */ dataId: string | null; /** UI string that describes on what data the breakpoint is set on or why a data breakpoint is not available. */ description: string; /** Optional attribute listing the available access types for a potential data breakpoint. A UI frontend could surface this information. */ accessTypes?: DataBreakpointAccessType[]; /** Optional attribute indicating that a potential data breakpoint could be persisted across sessions. */ canPersist?: boolean; }; } /** SetDataBreakpoints request; value of command field is 'setDataBreakpoints'. Replaces all existing data breakpoints with new data breakpoints. To clear all data breakpoints, specify an empty array. When a data breakpoint is hit, a 'stopped' event (with reason 'data breakpoint') is generated. Clients should only call this request if the capability 'supportsDataBreakpoints' is true. */ interface SetDataBreakpointsRequest extends Request { arguments: SetDataBreakpointsArguments; } /** Arguments for 'setDataBreakpoints' request. */ interface SetDataBreakpointsArguments { /** The contents of this array replaces all existing data breakpoints. An empty array clears all data breakpoints. */ breakpoints: DataBreakpoint[]; } /** Response to 'setDataBreakpoints' request. Returned is information about each breakpoint created by this request. */ interface SetDataBreakpointsResponse extends Response { body: { /** Information about the data breakpoints. The array elements correspond to the elements of the input argument 'breakpoints' array. */ breakpoints: Breakpoint[]; }; } /** SetInstructionBreakpoints request; value of command field is 'setInstructionBreakpoints'. Replaces all existing instruction breakpoints. Typically, instruction breakpoints would be set from a diassembly window. To clear all instruction breakpoints, specify an empty array. When an instruction breakpoint is hit, a 'stopped' event (with reason 'instruction breakpoint') is generated. Clients should only call this request if the capability 'supportsInstructionBreakpoints' is true. */ interface SetInstructionBreakpointsRequest extends Request { arguments: SetInstructionBreakpointsArguments; } /** Arguments for 'setInstructionBreakpoints' request */ interface SetInstructionBreakpointsArguments { /** The instruction references of the breakpoints */ breakpoints: InstructionBreakpoint[]; } /** Response to 'setInstructionBreakpoints' request */ interface SetInstructionBreakpointsResponse extends Response { body: { /** Information about the breakpoints. The array elements correspond to the elements of the 'breakpoints' array. */ breakpoints: Breakpoint[]; }; } /** Continue request; value of command field is 'continue'. The request resumes execution of all threads. If the debug adapter supports single thread execution (see capability 'supportsSingleThreadExecutionRequests') setting the 'singleThread' argument to true resumes only the specified thread. If not all threads were resumed, the 'allThreadsContinued' attribute of the response must be set to false. */ interface ContinueRequest extends Request { arguments: ContinueArguments; } /** Arguments for 'continue' request. */ interface ContinueArguments { /** Specifies the active thread. If the debug adapter supports single thread execution (see 'supportsSingleThreadExecutionRequests') and the optional argument 'singleThread' is true, only the thread with this ID is resumed. */ threadId: number; /** If this optional flag is true, execution is resumed only for the thread with given 'threadId'. */ singleThread?: boolean; } /** Response to 'continue' request. */ interface ContinueResponse extends Response { body: { /** The value true (or a missing property) signals to the client that all threads have been resumed. The value false must be returned if not all threads were resumed. */ allThreadsContinued?: boolean; }; } /** Next request; value of command field is 'next'. The request executes one step (in the given granularity) for the specified thread and allows all other threads to run freely by resuming them. If the debug adapter supports single thread execution (see capability 'supportsSingleThreadExecutionRequests') setting the 'singleThread' argument to true prevents other suspended threads from resuming. The debug adapter first sends the response and then a 'stopped' event (with reason 'step') after the step has completed. */ interface NextRequest extends Request { arguments: NextArguments; } /** Arguments for 'next' request. */ interface NextArguments { /** Specifies the thread for which to resume execution for one step (of the given granularity). */ threadId: number; /** If this optional flag is true, all other suspended threads are not resumed. */ singleThread?: boolean; /** Optional granularity to step. If no granularity is specified, a granularity of 'statement' is assumed. */ granularity?: SteppingGranularity; } /** Response to 'next' request. This is just an acknowledgement, so no body field is required. */ interface NextResponse extends Response { } /** StepIn request; value of command field is 'stepIn'. The request resumes the given thread to step into a function/method and allows all other threads to run freely by resuming them. If the debug adapter supports single thread execution (see capability 'supportsSingleThreadExecutionRequests') setting the 'singleThread' argument to true prevents other suspended threads from resuming. If the request cannot step into a target, 'stepIn' behaves like the 'next' request. The debug adapter first sends the response and then a 'stopped' event (with reason 'step') after the step has completed. If there are multiple function/method calls (or other targets) on the source line, the optional argument 'targetId' can be used to control into which target the 'stepIn' should occur. The list of possible targets for a given source line can be retrieved via the 'stepInTargets' request. */ interface StepInRequest extends Request { arguments: StepInArguments; } /** Arguments for 'stepIn' request. */ interface StepInArguments { /** Specifies the thread for which to resume execution for one step-into (of the given granularity). */ threadId: number; /** If this optional flag is true, all other suspended threads are not resumed. */ singleThread?: boolean; /** Optional id of the target to step into. */ targetId?: number; /** Optional granularity to step. If no granularity is specified, a granularity of 'statement' is assumed. */ granularity?: