- All Superinterfaces:
JavaSourceResolver
- All Known Implementing Classes:
DebuggeeAgent
Qute debugger API.
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddDebuggerListener(DebuggerListener listener) Registers a debugger listener to receive debug events.CompletableFuture<org.eclipse.lsp4j.debug.CompletionsResponse> completions(org.eclipse.lsp4j.debug.CompletionsArguments args) Provides code completions for the specified context.CompletableFuture<org.eclipse.lsp4j.debug.EvaluateResponse> Evaluates the given expression in the context of the specified frame.org.eclipse.lsp4j.debug.Scope[]getScopes(int frameId) Returns the variable scopes for the given stack frame.org.eclipse.lsp4j.debug.SourceResponsegetSourceReference(int sourceReference) Returns the source code template for a given source reference.org.eclipse.lsp4j.debug.StackTraceResponsegetStackFrames(int threadId, Integer startFrame, Integer levels) Returns the stack frames for the specified thread.getState(int threadId) Returns the current state of the remote debugger for a given thread.org.eclipse.lsp4j.debug.ThreadgetThread(int threadId) Returns the thread with the given ID.org.eclipse.lsp4j.debug.Thread[]Returns the list of threads known to the debugger.org.eclipse.lsp4j.debug.Variable[]getVariables(int variablesReference) Retrieves the variables for a given variable reference.booleanReturns whether the debugger is currently enabled.voidnext(int threadId) Moves to the next statement for the given thread (alias for step over).voidpause(int threadId) Pauses the execution of the template engine on the specified thread.voidremoveDebuggerListener(DebuggerListener listener) Unregisters a previously registered debugger listener.voidresume(int threadId) Resumes the execution of the template engine on the specified thread.org.eclipse.lsp4j.debug.Breakpoint[]setBreakpoints(org.eclipse.lsp4j.debug.SourceBreakpoint[] sourceBreakpoints, org.eclipse.lsp4j.debug.Source source) Sets breakpoints in a source file.voidsetEnabled(boolean enabled) Enables or disables the debugger.voidstepIn(int threadId) Performs a "step in" operation for the given thread.voidstepOut(int threadId) Performs a "step out" operation for the given thread.voidstepOver(int threadId) Performs a "step over" operation for the given thread.voidTerminates the debugging session.Methods inherited from interface io.quarkus.qute.debug.client.JavaSourceResolver
resolveJavaSource
-
Method Details
-
getState
Returns the current state of the remote debugger for a given thread.- Parameters:
threadId- the ID of the thread- Returns:
- the current
DebuggerStateof the thread
-
pause
void pause(int threadId) Pauses the execution of the template engine on the specified thread.- Parameters:
threadId- the ID of the thread to pause
-
resume
void resume(int threadId) Resumes the execution of the template engine on the specified thread.- Parameters:
threadId- the ID of the thread to resume
-
setBreakpoints
org.eclipse.lsp4j.debug.Breakpoint[] setBreakpoints(org.eclipse.lsp4j.debug.SourceBreakpoint[] sourceBreakpoints, org.eclipse.lsp4j.debug.Source source) Sets breakpoints in a source file.- Parameters:
sourceBreakpoints- the breakpoints to setsource- the source file where breakpoints are applied- Returns:
- the actual breakpoints that were set
-
getThreads
org.eclipse.lsp4j.debug.Thread[] getThreads()Returns the list of threads known to the debugger.- Returns:
- an array of
Threadobjects
-
getThread
org.eclipse.lsp4j.debug.Thread getThread(int threadId) Returns the thread with the given ID.- Parameters:
threadId- the ID of the thread- Returns:
- the corresponding
Threadobject
-
getStackFrames
org.eclipse.lsp4j.debug.StackTraceResponse getStackFrames(int threadId, Integer startFrame, Integer levels) Returns the stack frames for the specified thread.- Parameters:
threadId- the ID of the threadstartFrame- the index of the first frame to return; if omitted frames start at 0.levels- the maximum number of frames to return. If levels is not specified or 0, all frames are returned.- Returns:
- an array of
StackFrameobjects and the total frames
-
getScopes
org.eclipse.lsp4j.debug.Scope[] getScopes(int frameId) Returns the variable scopes for the given stack frame.- Parameters:
frameId- the ID of the stack frame- Returns:
- an array of
Scopeobjects
-
getVariables
org.eclipse.lsp4j.debug.Variable[] getVariables(int variablesReference) Retrieves the variables for a given variable reference.- Parameters:
variablesReference- the reference ID for the variable- Returns:
- an array of child
Variableobjects
-
evaluate
CompletableFuture<org.eclipse.lsp4j.debug.EvaluateResponse> evaluate(Integer frameId, String expression, String context) Evaluates the given expression in the context of the specified frame.- Parameters:
frameId- the ID of the stack frame (nullable)expression- the expression to evaluatecontext- the evaludation context- Returns:
- a
CompletableFuturethat completes with the evaluation result
-
terminate
void terminate()Terminates the debugging session. -
stepIn
void stepIn(int threadId) Performs a "step in" operation for the given thread.- Parameters:
threadId- the ID of the thread
-
stepOut
void stepOut(int threadId) Performs a "step out" operation for the given thread.- Parameters:
threadId- the ID of the thread
-
stepOver
void stepOver(int threadId) Performs a "step over" operation for the given thread.- Parameters:
threadId- the ID of the thread
-
next
void next(int threadId) Moves to the next statement for the given thread (alias for step over).- Parameters:
threadId- the ID of the thread
-
completions
CompletableFuture<org.eclipse.lsp4j.debug.CompletionsResponse> completions(org.eclipse.lsp4j.debug.CompletionsArguments args) Provides code completions for the specified context.- Parameters:
args- theCompletionsArgumentsfor the current context- Returns:
- a
CompletableFuture<org.eclipse.lsp4j.debug.CompletionsResponse>with the suggested completions
-
getSourceReference
org.eclipse.lsp4j.debug.SourceResponse getSourceReference(int sourceReference) Returns the source code template for a given source reference.- Parameters:
sourceReference- the source reference- Returns:
- the source code template for a given source reference
-
addDebuggerListener
Registers a debugger listener to receive debug events.- Parameters:
listener- the listener to register
-
removeDebuggerListener
Unregisters a previously registered debugger listener.- Parameters:
listener- the listener to remove
-
setEnabled
void setEnabled(boolean enabled) Enables or disables the debugger.- Parameters:
enabled-trueto enable the debugger,falseto disable it
-
isEnabled
boolean isEnabled()Returns whether the debugger is currently enabled.- Returns:
trueif enabled,falseotherwise
-