(response: DebugProtocol.SetBreakpointsResponse, args: DebugProtocol.SetBreakpointsArguments)
| 228 | } |
| 229 | |
| 230 | protected setBreakPointsRequest(response: DebugProtocol.SetBreakpointsResponse, args: DebugProtocol.SetBreakpointsArguments): void { |
| 231 | let path = args.source.path; |
| 232 | if (this.isSSH) { |
| 233 | // convert local path to ssh path |
| 234 | path = this.sourceFileMap.toRemotePath(path); |
| 235 | } |
| 236 | this.miDebugger.clearBreakPoints(path).then(() => { |
| 237 | const all = args.breakpoints.map(brk => { |
| 238 | return this.miDebugger.addBreakPoint({ file: path, line: brk.line, condition: brk.condition, countCondition: brk.hitCondition }); |
| 239 | }); |
| 240 | Promise.all(all).then(brkpoints => { |
| 241 | const finalBrks = []; |
| 242 | brkpoints.forEach(brkp => { |
| 243 | // TODO: Currently all breakpoints returned are marked as verified, |
| 244 | // which leads to verified breakpoints on a broken lldb. |
| 245 | if (brkp[0]) |
| 246 | finalBrks.push(new DebugAdapter.Breakpoint(true, brkp[1].line)); |
| 247 | }); |
| 248 | response.body = { |
| 249 | breakpoints: finalBrks |
| 250 | }; |
| 251 | this.sendResponse(response); |
| 252 | }, msg => { |
| 253 | this.sendErrorResponse(response, 9, msg.toString()); |
| 254 | }); |
| 255 | }, msg => { |
| 256 | this.sendErrorResponse(response, 9, msg.toString()); |
| 257 | }); |
| 258 | } |
| 259 | |
| 260 | protected threadsRequest(response: DebugProtocol.ThreadsResponse): void { |
| 261 | if (!this.miDebugger) { |
nothing calls this directly
no test coverage detected