|
Java Debug Interface | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Manages the creation and deletion of EventRequest
s. A single
implementor of this interface exists in a particuar VM and
is accessed through VirtualMachine.eventRequestManager()
EventRequest
,
Event
,
BreakpointRequest
,
BreakpointEvent
,
VirtualMachine
Methods inherited from interface com.sun.jdi.Mirror |
toString, virtualMachine |
Method Detail |
public ClassPrepareRequest createClassPrepareRequest()
ClassPrepareRequest
.
The new event request is added to the list managed by this
EventRequestManager. Use EventRequest.enable()
to
activate this event request.ClassPrepareRequest
public ClassUnloadRequest createClassUnloadRequest()
ClassUnloadRequest
.
The new event request is added to the list managed by this
EventRequestManager. Use EventRequest.enable()
to
activate this event request.ClassUnloadRequest
public ThreadStartRequest createThreadStartRequest()
ThreadStartRequest
.
The new event request is added to the list managed by this
EventRequestManager. Use EventRequest.enable()
to
activate this event request.ThreadStartRequest
public ThreadDeathRequest createThreadDeathRequest()
ThreadDeathRequest
.
The new event request is added to the list managed by this
EventRequestManager. Use EventRequest.enable()
to
activate this event request.ThreadDeathRequest
public ExceptionRequest createExceptionRequest(ReferenceType refType, boolean notifyCaught, boolean notifyUncaught)
ExceptionRequest
.
The new event request is added to the list managed by this
EventRequestManager. Use EventRequest.enable()
to
activate this event request.
A specific exception type and its subclasses can be selected
for exception events. Caught exceptions, uncaught exceptions,
or both can be selected. Note, however, that
at the time an exception is thrown, it is not always
possible to determine whether it is truly caught. See
ExceptionEvent.catchLocation()
for
details.
refType
- If non-null, specifies that exceptions which are
instances of refType will be reported. Note: this
will include instances of sub-types. If null,
all instances will be reportednotifyCaught
- If true, caught exceptions will be reported.notifyUncaught
- If true, uncaught exceptions will be reported.ExceptionRequest
VMMismatchException
- if refType and this EventRequestManager
do not belong to the same VirtualMachine
.public MethodEntryRequest createMethodEntryRequest()
MethodEntryRequest
.
The new event request is added to the list managed by this
EventRequestManager. Use EventRequest.enable()
to
activate this event request.MethodEntryRequest
public MethodExitRequest createMethodExitRequest()
MethodExitRequest
.
The new event request is added to the list managed by this
EventRequestManager. Use EventRequest.enable()
to
activate this event request.MethodExitRequest
public StepRequest createStepRequest(ThreadReference thread, int size, int depth)
StepRequest
.
The new event request is added to the list managed by this
EventRequestManager. Use EventRequest.enable()
to
activate this event request.
The returned request will control stepping only in the specified
thread
; all other threads will be unaffected.
A size
value of StepRequest.STEP_MIN
will generate a
step event each time the code index changes. It represents the
smallest step size available and often maps to the instruction
level.
A size
value of StepRequest.STEP_LINE
will generate a
step event each time the source line changes. A
depth
value of StepRequest.STEP_INTO
will generate
step events in any called methods. A depth
value
of StepRequest.STEP_OVER
restricts step events to the current frame
or caller frames. A depth
value of StepRequest.STEP_OUT
restricts step events to caller frames only. All depth
restrictions are relative to the call stack immediately before the
step takes place.
Only one pending step request is allowed per thread.
Note that a typical debugger will want to cancel stepping
after the first step is detected. Thus a next line method
would do the following:
EventRequestManager mgr = myVM.
eventRequestManager
();
StepRequest request = mgr.createStepRequest(myThread,
StepRequest.STEP_LINE
,
StepRequest.STEP_OVER
);
request.addCountFilter
(1); // next step only
request.enable();
myVM.resume
();
thread
- the thread in which to stepdepth
- the step depthsize
- the step sizeStepRequest
DuplicateRequestException
- if there is already a pending
step request for the specified thread.ObjectCollectedException
- if the thread object has been
garbage collected.VMMismatchException
- if thread and this EventRequestManager
do not belong to the same VirtualMachine
.
public BreakpointRequest createBreakpointRequest(Location location)
BreakpointRequest
.
The given Location
must have a valid
(that is, non-negative) code index. The new
breakpoint is added to the list managed by this
EventRequestManager. Multiple breakpoints at the
same location are permitted. Use EventRequest.enable()
to
activate this event request.location
- the location of the new breakpoint.BreakpointRequest
NullPointerException
- if location is null.VMMismatchException
- if location and this EventRequestManager
do not belong to the same VirtualMachine
.public AccessWatchpointRequest createAccessWatchpointRequest(Field field)
EventRequest.enable()
to
activate this event request.field
- the field to watchNullPointerException
- if field is null.VMMismatchException
- if field and this EventRequestManager
do not belong to the same VirtualMachine
.public ModificationWatchpointRequest createModificationWatchpointRequest(Field field)
EventRequest.enable()
to
activate this event request.field
- the field to watchNullPointerException
- if field is null.VMMismatchException
- if field and this EventRequestManager
do not belong to the same VirtualMachine
.public void deleteEventRequest(EventRequest eventRequest)
EventRequest.setEnabled(boolean)
)
are permitted. No other eventRequests are effected.eventRequest
- the eventRequest to removeVMMismatchException
- if a Mirror
argument and this mirror
do not belong to the same VirtualMachine
.public void deleteEventRequests(List eventRequests)
EventRequest
s.eventRequests
- the list of eventRequests to removeVMMismatchException
- if a Mirror
argument and this mirror
do not belong to the same VirtualMachine
.deleteEventRequest(EventRequest)
public void deleteAllBreakpoints()
deleteEventRequest(EventRequest)
public List stepRequests()
StepRequest
objects.public List classPrepareRequests()
ClassPrepareRequest
objects.public List classUnloadRequests()
ClassUnloadRequest
objects.public List threadStartRequests()
ThreadStartRequest
objects.public List threadDeathRequests()
ThreadDeathRequest
objects.public List exceptionRequests()
ExceptionRequest
objects.public List breakpointRequests()
BreakpointRequest
objects.public List accessWatchpointRequests()
AccessWatchpointRequest
objects.public List modificationWatchpointRequests()
ModificationWatchpointRequest
objects.public List methodEntryRequests()
MethodEntryRequest
objects.public List methodExitRequests()
MethodExitRequest
objects.
|
Java Debug Interface | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |