public interface JPDAThread
Since JDI interfaces evolve from one version to another, it's strongly recommended not to implement this interface in client code. New methods can be added to this interface at any time to keep up with the JDI functionality.
Modifier and Type | Field and Description |
---|---|
static String |
PROP_BREAKPOINT
Property name constant.
|
static String |
PROP_CALLSTACK
Property name constant.
|
static String |
PROP_SUSPENDED
Suspended property of the thread.
|
static String |
PROP_VARIABLES
Property name constant.
|
static int |
STATE_MONITOR
Thread state constant.
|
static int |
STATE_NOT_STARTED
Thread state constant.
|
static int |
STATE_RUNNING
Thread state constant.
|
static int |
STATE_SLEEPING
Thread state constant.
|
static int |
STATE_UNKNOWN
Thread state constant.
|
static int |
STATE_WAIT
Thread state constant.
|
static int |
STATE_ZOMBIE
Thread state constant.
|
Modifier and Type | Method and Description |
---|---|
CallStackFrame[] |
getCallStack()
Returns call stack for this thread.
|
CallStackFrame[] |
getCallStack(int from,
int to)
Returns call stack for this thread on the given indexes.
|
String |
getClassName()
If this thread is suspended returns class name this thread is
stopped in.
|
ObjectVariable |
getContendedMonitor()
Returns monitor this thread is waiting on.
|
MonitorInfo |
getContendedMonitorAndOwner()
Returns monitor this thread is waiting on, with the information
about the owner of the monitor.
|
JPDABreakpoint |
getCurrentBreakpoint()
Returns the current breakpoint hit by this thread.
|
EditorContext.Operation |
getCurrentOperation()
Returns the operation that is being currently executed on this thread.
|
List<EditorContext.Operation> |
getLastOperations()
Returns the list of the last operations, that were performed on this thread.
|
int |
getLineNumber(String stratum)
Returns line number of the location this thread stopped at.
|
String |
getMethodName()
If this thread is suspended returns method name this thread is
stopped in.
|
String |
getName()
Getter for the name of thread property.
|
ObjectVariable[] |
getOwnedMonitors()
Returns monitors owned by this thread.
|
List<MonitorInfo> |
getOwnedMonitorsAndFrames()
Get the list of monitors with stack frame info owned by this thread.
|
JPDAThreadGroup |
getParentThreadGroup()
Returns parent thread group.
|
Lock |
getReadAccessLock()
Getter for the "read" lock under which it's guaranteed that the thread
does not change it's suspended state.
|
String |
getSourceName(String stratum)
Returns file name this frame is stopped in or null.
|
String |
getSourcePath(String stratum)
Returns source path of file this frame is stopped in or null.
|
int |
getStackDepth()
Returns length of current call stack.
|
int |
getState()
Returns current state of this thread.
|
void |
interrupt()
Interrupts this thread unless the thread has been suspended.
|
boolean |
isSuspended()
Returns true if this thread is suspended by debugger.
|
void |
makeCurrent()
Sets this thread current.
|
void |
resume()
Unsuspends thread.
|
void |
suspend()
Suspends thread.
|
static final int STATE_UNKNOWN
static final int STATE_MONITOR
static final int STATE_NOT_STARTED
static final int STATE_RUNNING
static final int STATE_SLEEPING
static final int STATE_WAIT
static final int STATE_ZOMBIE
static final String PROP_SUSPENDED
static final String PROP_CALLSTACK
static final String PROP_VARIABLES
static final String PROP_BREAKPOINT
Lock getReadAccessLock()
String getName()
JPDAThreadGroup getParentThreadGroup()
int getLineNumber(String stratum)
-1
otherwiseCallStackFrame
EditorContext.Operation getCurrentOperation()
null
.CallStackFrame#getCurrentOperation}
JPDABreakpoint getCurrentBreakpoint()
null
.List<EditorContext.Operation> getLastOperations()
null
otherwiseCallStackFrame
int getState()
boolean isSuspended()
String getClassName()
String getMethodName()
void suspend()
void resume()
void interrupt()
String getSourceName(String stratum) throws com.sun.jdi.AbsentInformationException
com.sun.jdi.AbsentInformationException
String getSourcePath(String stratum) throws com.sun.jdi.AbsentInformationException
com.sun.jdi.AbsentInformationException
CallStackFrame[] getCallStack() throws com.sun.jdi.AbsentInformationException
com.sun.jdi.AbsentInformationException
- if the thread is running or not able
to return callstack. If the thread is in an incompatible state
(e.g. running), the AbsentInformationException has
IncompatibleThreadStateException as a cause.CallStackFrame[] getCallStack(int from, int to) throws com.sun.jdi.AbsentInformationException
from
- a from index, inclusiveto
- a to index, exclusivecom.sun.jdi.AbsentInformationException
- if the thread is running or not able
to return callstack. If the thread is in an incompatible state
(e.g. running), the AbsentInformationException has
IncompatibleThreadStateException as a cause.int getStackDepth()
void makeCurrent()
JPDADebugger.getCurrentThread()
ObjectVariable getContendedMonitor()
MonitorInfo getContendedMonitorAndOwner()
ObjectVariable[] getOwnedMonitors()
List<MonitorInfo> getOwnedMonitorsAndFrames()