Package stdlib
Class JDIEventMonitor
java.lang.Object
java.lang.Thread
stdlib.JDIEventMonitor
- All Implemented Interfaces:
Runnable
Monitor incoming JDI events for a program running in the JVM and print out
trace/debugging information.
This is a simplified version of EventThread.java from the Trace.java example
in the demo/jpda/examples.jar file in the JDK.
Andrew Davison: The main addition is the use of the ShowCodes and ShowLines
classes to list the line being currently executed.
James Riely: See comments in class Trace.
- Author:
- Robert Field and Minoru Terada, September 2005, Iman_S, June 2008, Andrew Davison, ad@fivedots.coe.psu.ac.th, March 2009, James Riely, jriely@cs.depaul.edu, August 2014
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Thread
Thread.Builder, Thread.State, Thread.UncaughtExceptionHandler -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate booleanprivate final JDIEventHandlerprivate final VirtualMachineprivate booleanFields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate voidprivate voidclassUnloadEvent(ClassUnloadEvent event) private voidexceptionEvent(ExceptionEvent event) private voidprivate voidhandleEvent(Event event) private voidmethodEntryEvent(MethodEntryEvent event) private voidmethodExitEvent(MethodExitEvent event) private voidprivate voidprivate voidprivate voidprivate voidmonitorWaitEvent(MonitorWaitEvent event) voidrun()private voidprivate voidprivate voidthreadDeathEvent(ThreadDeathEvent event) private voidthreadStartEvent(ThreadStartEvent event) private voidvmDeathEvent(VMDeathEvent event) private voidprivate voidvmStartEvent(VMStartEvent event) Methods inherited from class java.lang.Thread
activeCount, checkAccess, clone, countStackFrames, currentThread, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, isVirtual, join, join, join, join, ofPlatform, ofVirtual, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, sleep, start, startVirtualThread, stop, suspend, threadId, toString, yield
-
Field Details
-
vm
-
connected
-
vmDied
-
printer
-
-
Constructor Details
-
JDIEventMonitor
-
-
Method Details
-
setEventRequests
-
run
-
handleEvent
-
handleDisconnectedException
-
vmStartEvent
-
vmDeathEvent
-
vmDisconnectEvent
-
classPrepareEvent
-
classUnloadEvent
-
threadStartEvent
-
threadDeathEvent
-
methodEntryEvent
-
methodExitEvent
-
exceptionEvent
-
stepEvent
-
modificationWatchpointEvent
-
monitorContendedEnterEvent
-
monitorContendedEnteredEvent
-
monitorWaitEvent
-
monitorWaitedEvent
-