public interface NIDebuggerProvider
Modifier and Type | Method and Description |
---|---|
Breakpoint |
addLineBreakpoint(Object id,
NILineBreakpointDescriptor breakpointDescriptor)
Add or change a line breakpoint into the debugger.
|
default CompletableFuture<Void> |
attach(String executablePath,
long processId,
String debugger,
java.util.function.Consumer<DebuggerEngine> startedEngine)
Deprecated.
Use
NIDebuggerProvider.start(StartDebugParameters, Consumer) and set StartDebugParameters.Builder#processID(Long) . |
CompletableFuture<NIVariable> |
evaluateAsync(String expression,
String resultName,
NIFrame frame)
An asynchronous expression evaluation.
|
String |
getVersion()
Get version of the underlying native debugger.
|
default Map<SourceInfo,List<Symbol>> |
listFunctions(String name,
boolean includeNondebug,
int maxResults)
Provide a list of functions in the debuggee.
|
default List<Location> |
listLocations(String filePath)
Provide a list of locations for a given file path.
|
default Map<SourceInfo,List<Symbol>> |
listVariables(String name,
boolean includeNondebug,
int maxResults)
Provide a list of global variables in the debuggee.
|
String |
readMemory(String address,
long offset,
int length)
Read data from memory.
|
void |
removeBreakpoint(Object id)
Remove breakpoint with the given id.
|
void |
setFrameDisplayer(FrameDisplayer frameDisplayer)
Set a displayer of native frames.
|
void |
setVariablesDisplayer(VariableDisplayer variablesDisplayer)
Set a displayer of native variables.
|
default CompletableFuture<Void> |
start(List<String> command,
File workingDirectory,
String debugger,
String displayName,
ExecutionDescriptor executionDescriptor,
java.util.function.Consumer<DebuggerEngine> startedEngine)
|
default CompletableFuture<Void> |
start(StartDebugParameters debugParameters,
java.util.function.Consumer<DebuggerEngine> startedEngine)
Start the actual debugging session.
|
Breakpoint addLineBreakpoint(Object id, NILineBreakpointDescriptor breakpointDescriptor)
id
- a unique ID of the breakpointbreakpointDescriptor
- the breakpoint descriptorvoid removeBreakpoint(Object id)
id
- the ID of the breakpoint to removevoid setFrameDisplayer(FrameDisplayer frameDisplayer)
frameDisplayer
- translator of the native frame to it's displayed informationvoid setVariablesDisplayer(VariableDisplayer variablesDisplayer)
variablesDisplayer
- translator of native variables to displayed variables.@Deprecated default CompletableFuture<Void> start(List<String> command, File workingDirectory, String debugger, String displayName, ExecutionDescriptor executionDescriptor, java.util.function.Consumer<DebuggerEngine> startedEngine)
NIDebuggerProvider.start(org.netbeans.modules.nativeimage.api.debug.StartDebugParameters, java.util.function.Consumer)
command
- a command to run the native imageworkingDirectory
- working directorydebugger
- the native debugger commanddisplayName
- display name of the debugger taskexecutionDescriptor
- execution descriptor that describes the runtime attributesstartedEngine
- the corresponding DebuggerEngine is passed to this consumerdefault CompletableFuture<Void> start(StartDebugParameters debugParameters, java.util.function.Consumer<DebuggerEngine> startedEngine)
debugParameters
- parameters to start the debugging withstartedEngine
- the corresponding DebuggerEngine is passed to this consumer@Deprecated default CompletableFuture<Void> attach(String executablePath, long processId, String debugger, java.util.function.Consumer<DebuggerEngine> startedEngine)
NIDebuggerProvider.start(StartDebugParameters, Consumer)
and set StartDebugParameters.Builder#processID(Long)
.executablePath
- path to an executable representing the native imageprocessId
- a process to attach todebugger
- the native debugger commandstartedEngine
- the corresponding DebuggerEngine is passed to this consumerCompletableFuture<NIVariable> evaluateAsync(String expression, String resultName, NIFrame frame)
expression
- the expression to evaluateresultName
- preferred name of the result variable,
when null
the expression is used as the nameframe
- the frame to evaluate atString readMemory(String address, long offset, int length)
address
- address where to read the data fromoffset
- offset relative to the address where to start readinglength
- number of bytes to readnull
when the read is not successfulString getVersion()
default List<Location> listLocations(String filePath)
filePath
- a file pathnull
when there's no location
information about such file.default Map<SourceInfo,List<Symbol>> listFunctions(String name, boolean includeNondebug, int maxResults)
default Map<SourceInfo,List<Symbol>> listVariables(String name, boolean includeNondebug, int maxResults)