本文整理匯總了TypeScript中vscode-debugadapter.DebugSession.run方法的典型用法代碼示例。如果您正苦於以下問題:TypeScript DebugSession.run方法的具體用法?TypeScript DebugSession.run怎麽用?TypeScript DebugSession.run使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類vscode-debugadapter.DebugSession
的用法示例。
在下文中一共展示了DebugSession.run方法的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1: continueRequest
console.log(args);
this.sendResponse(response);
}
protected continueRequest(response: DebugProtocol.ContinueResponse, args: DebugProtocol.ContinueArguments): void {
console.log(args);
this.sendResponse(response);
// no more lines: run to end
this.sendEvent(new TerminatedEvent());
}
protected nextRequest(response: DebugProtocol.NextResponse, args: DebugProtocol.NextArguments): void {
console.log(args);
this.sendResponse(response);
// no more lines: run to end
this.sendEvent(new TerminatedEvent());
}
protected stepBackRequest(response: DebugProtocol.StepBackResponse, args: DebugProtocol.StepBackArguments): void {
console.log(args);
this.sendResponse(response);
}
protected evaluateRequest(response: DebugProtocol.EvaluateResponse, args: DebugProtocol.EvaluateArguments): void {
console.log(args);
this.sendResponse(response);
}
}
DebugSession.run(C4EarthDebugSession);
示例2: setTimeout
setTimeout(() => {
this.miDebugger.emit("ui-break-done");
}, 50);
this.sendResponse(response);
this.miDebugger.start().then(() => {
this.started = true;
if (this.crashed)
this.handlePause(undefined);
});
});
}
}
protected attachRequest(response: DebugProtocol.AttachResponse, args: AttachRequestArguments): void {
this.quit = false;
this.attached = true;
this.needContinue = true;
this.isSSH = false;
this.miDebugger.printCalls = !!args.printCalls;
this.miDebugger.attach(args.cwd, args.executable, args.target).then(() => {
if (args.autorun)
args.autorun.forEach(command => {
this.miDebugger.sendUserInput(command);
});
this.sendResponse(response);
});
}
}
DebugSession.run(LLDBDebugSession);
示例3:
import { DebugSession } from "vscode-debugadapter";
import { DartTestDebugSession } from "./dart_test_debug_impl";
DebugSession.run(DartTestDebugSession);
示例4: nextRequest
this.sendResponse(response);
}
protected nextRequest(response: DebugProtocol.NextResponse,
args: DebugProtocol.NextArguments): void {
this.sendStep("stepOver", response, args);
}
protected continueRequest(response: DebugProtocol.ContinueResponse,
args: DebugProtocol.ContinueArguments): void {
this.sendStep("resume", response, args);
}
protected stepInRequest(response: DebugProtocol.StepInResponse,
args: DebugProtocol.StepInArguments): void {
this.sendStep("stepInto", response, args);
}
protected stepOutRequest(response: DebugProtocol.StepOutResponse,
args: DebugProtocol.StepOutArguments): void {
this.sendStep("return", response, args);
}
protected pauseRequest(response: DebugProtocol.PauseResponse,
args: DebugProtocol.PauseArguments): void {
this.sendStep("stop", response, args);
}
}
DebugSession.run(SomDebugSession);
示例5: attachRequest
}
protected attachRequest(response: DebugProtocol.AttachResponse, args: AttachRequestArguments): void {
this.quit = false;
this.attached = !args.remote;
this.needContinue = true;
this.isSSH = false;
this.miDebugger.printCalls = !!args.printCalls;
if (args.remote) {
this.miDebugger.connect(args.cwd, args.executable, args.target).then(() => {
if (args.autorun)
args.autorun.forEach(command => {
this.miDebugger.sendUserInput(command);
});
this.sendResponse(response);
});
}
else {
this.miDebugger.attach(args.cwd, args.executable, args.target).then(() => {
if (args.autorun)
args.autorun.forEach(command => {
this.miDebugger.sendUserInput(command);
});
this.sendResponse(response);
});
}
}
}
DebugSession.run(GDBDebugSession);
示例6:
import { DebugSession } from "vscode-debugadapter";
import { FlutterWebTestDebugSession } from "./flutter_web_test_debug_impl";
DebugSession.run(FlutterWebTestDebugSession);
示例7:
/*---------------------------------------------------------
* Copyright (C) Microsoft Corporation. All rights reserved.
*--------------------------------------------------------*/
import {WebKitDebugSession} from './webKitDebugSession';
import {DebugSession} from 'vscode-debugadapter';
DebugSession.run(WebKitDebugSession);
示例8:
import { DebugSession } from "vscode-debugadapter";
import { FlutterDebugSession } from "./flutter_debug_impl";
DebugSession.run(FlutterDebugSession);
示例9: pauseRequest
this.sendErrorResponse(response, 2000, 'Step out is not yet supported');
}
protected pauseRequest(response: DebugProtocol.PauseResponse): void {
console.error('Not yet implemented: pauseRequest');
this.sendErrorResponse(response, 2000, 'Pause is not yet supported');
}
protected evaluateRequest(response: DebugProtocol.EvaluateResponse, args: DebugProtocol.EvaluateArguments): void {
console.log('EvaluateRequest');
let evalSymbolArgs = {
symbol: args.expression,
scope: {
goroutineID: this.debugState.currentGoroutine.id,
frame: args.frameId
}
};
this.delve.call<DebugVariable>('EvalSymbol', [evalSymbolArgs], (err, variable) => {
if (err) {
console.error('Failed to eval expression: ', JSON.stringify(evalSymbolArgs, null, ' '));
return this.sendErrorResponse(response, 2009, 'Unable to eval expression: "{e}"', { e: err.toString() });
}
response.body = this.convertDebugVariableToProtocolVariable(variable, 0);
this.sendResponse(response);
console.log('EvaluateResponse');
});
}
}
DebugSession.run(GoDebugSession);
示例10:
/*---------------------------------------------------------
* Copyright (C) Microsoft Corporation. All rights reserved.
*--------------------------------------------------------*/
import {ChromeDebugSession} from './chromeDebugSession';
import {DebugSession} from 'vscode-debugadapter';
DebugSession.run(ChromeDebugSession);