public abstract class ListenerAdapter extends Object implements VMListener, SearchListener, PublisherExtension
| Constructor and Description |
|---|
ListenerAdapter() |
| Modifier and Type | Method and Description |
|---|---|
void |
choiceGeneratorAdvanced(VM vm,
ChoiceGenerator<?> currentCG)
the next choice was requested from a previously registered ChoiceGenerator
NOTE - this notification happens before the KernelState is stored, i.e.
|
void |
choiceGeneratorProcessed(VM vm,
ChoiceGenerator<?> processedCG)
a ChoiceGnerator has returned all his choices
NOTE - this notification happens before the KernelState is stored, i.e.
|
void |
choiceGeneratorRegistered(VM vm,
ChoiceGenerator<?> nextCG,
ThreadInfo currentThread,
Instruction executedInstruction)
next ChoiceGenerator was registered, which means this is the end of the current transition
the reason why we have this in addition to the choiceGeneratorSet is that listeners
can reset the registered CG and so force the current transition to continue (although the
listener in this case has to make sure the operand stack is in a consistent state for
continued execution because there might be a bottom half of an Instruction.execute() missing)
|
void |
choiceGeneratorSet(VM vm,
ChoiceGenerator<?> newCG)
a new ChoiceGenerator was set, which means we are at the beginning of a new transition.
|
void |
classLoaded(VM vm,
ClassInfo loadedClass)
new class was loaded.
|
void |
exceptionBailout(VM vm,
ThreadInfo currentThread)
exception causes top frame to be purged
|
void |
exceptionHandled(VM vm,
ThreadInfo currentThread)
exception handled by current top frame
|
void |
exceptionThrown(VM vm,
ThreadInfo currentThread,
ElementInfo thrownException)
exception was thrown
|
void |
executeInstruction(VM vm,
ThreadInfo currentThread,
Instruction instructionToExecute)
VM is about to execute the next instruction
|
void |
gcBegin(VM vm) |
void |
gcEnd(VM vm) |
void |
instructionExecuted(VM vm,
ThreadInfo currentThread,
Instruction nextInstruction,
Instruction executedInstruction)
VM has executed the next instruction
(can be used to analyze branches, monitor PUTFIELD / GETFIELD and
INVOKExx / RETURN instructions)
|
void |
loadClass(VM vm,
ClassFile cf)
a new classfile is about to be parsed.
|
void |
methodEntered(VM vm,
ThreadInfo currentThread,
MethodInfo enteredMethod)
method body was entered.
|
void |
methodExited(VM vm,
ThreadInfo currentThread,
MethodInfo exitedMethod)
method body was left.
|
void |
objectCreated(VM vm,
ThreadInfo currentThread,
ElementInfo newObject)
new object was created
|
void |
objectLocked(VM vm,
ThreadInfo currentThread,
ElementInfo lockedObject)
notify if an object lock was taken (this includes automatic
surrender during a wait())
|
void |
objectNotify(VM vm,
ThreadInfo currentThread,
ElementInfo notifyingObject)
notify if an object notifies a single waiter
|
void |
objectNotifyAll(VM vm,
ThreadInfo currentThread,
ElementInfo notifyingObject)
notify if an object notifies all waiters
|
void |
objectReleased(VM vm,
ThreadInfo currentThread,
ElementInfo releasedObject)
object was garbage collected (after potential finalization)
|
void |
objectUnlocked(VM vm,
ThreadInfo currentThread,
ElementInfo unlockedObject)
notify if an object lock was released (this includes automatic
reacquisition after a notify())
|
void |
objectWait(VM vm,
ThreadInfo currentThread,
ElementInfo waitingObject)
notify if a wait() is executed
|
void |
propertyViolated(Search search)
JPF encountered a property violation.
|
void |
publishConstraintHit(Publisher publisher) |
void |
publishFinished(Publisher publisher) |
void |
publishPropertyViolation(Publisher publisher) |
void |
publishStart(Publisher publisher) |
void |
publishTransition(Publisher publisher) |
void |
searchConstraintHit(Search search)
there was some contraint hit in the search, we back out
could have been turned into a property, but usually is an attribute of
the search, not the application
|
void |
searchFinished(Search search)
we're done, either with or without a preceeding error
|
void |
searchStarted(Search search)
we get this after we enter the search loop, but BEFORE the first forward
|
void |
stateAdvanced(Search search)
got the next state
Note - this will be notified before any potential propertyViolated, in which
case the currentError will be already set
|
void |
stateBacktracked(Search search)
state was backtracked one step
|
void |
stateProcessed(Search search)
state is fully explored
|
void |
statePurged(Search search)
some state is not going to appear in any path anymore
|
void |
stateRestored(Search search)
a previously generated state was restored
(can be on a completely different path)
|
void |
stateStored(Search search)
somebody stored the state
|
void |
threadBlocked(VM vm,
ThreadInfo blockedThread,
ElementInfo lock)
thread waits to acquire a lock
// NOTE: vm.getLastThreadInfo() does NOT have to be the running thread, as this
// notification can occur as a result of a lock operation in the current thread
|
void |
threadInterrupted(VM vm,
ThreadInfo interruptedThread)
thread got interrupted
|
void |
threadNotified(VM vm,
ThreadInfo notifiedThread)
thread got notified
|
void |
threadScheduled(VM vm,
ThreadInfo scheduledThread)
new thread was scheduled by VM
|
void |
threadStarted(VM vm,
ThreadInfo startedThread)
new Thread entered run() method
|
void |
threadTerminated(VM vm,
ThreadInfo terminatedThread)
Thread exited run() method
|
void |
threadWaiting(VM vm,
ThreadInfo waitingThread)
thread is waiting for signal
|
void |
vmInitialized(VM vm)
VM got initialized (but search is not yet running).
|
public void vmInitialized(VM vm)
VMListenervmInitialized in interface VMListenerpublic void instructionExecuted(VM vm, ThreadInfo currentThread, Instruction nextInstruction, Instruction executedInstruction)
VMListenerinstructionExecuted in interface VMListenerpublic void executeInstruction(VM vm, ThreadInfo currentThread, Instruction instructionToExecute)
VMListenerexecuteInstruction in interface VMListenerpublic void threadStarted(VM vm, ThreadInfo startedThread)
VMListenerthreadStarted in interface VMListenerpublic void threadWaiting(VM vm, ThreadInfo waitingThread)
VMListenerthreadWaiting in interface VMListenerpublic void threadNotified(VM vm, ThreadInfo notifiedThread)
VMListenerthreadNotified in interface VMListenerpublic void threadInterrupted(VM vm, ThreadInfo interruptedThread)
VMListenerthreadInterrupted in interface VMListenerpublic void threadScheduled(VM vm, ThreadInfo scheduledThread)
VMListenerthreadScheduled in interface VMListenerpublic void threadBlocked(VM vm, ThreadInfo blockedThread, ElementInfo lock)
VMListenerthreadBlocked in interface VMListenerpublic void threadTerminated(VM vm, ThreadInfo terminatedThread)
VMListenerthreadTerminated in interface VMListenerpublic void loadClass(VM vm, ClassFile cf)
VMListenerloadClass in interface VMListenerpublic void classLoaded(VM vm, ClassInfo loadedClass)
VMListenerclassLoaded in interface VMListenerpublic void objectCreated(VM vm, ThreadInfo currentThread, ElementInfo newObject)
VMListenerobjectCreated in interface VMListenerpublic void objectReleased(VM vm, ThreadInfo currentThread, ElementInfo releasedObject)
VMListenerobjectReleased in interface VMListenerpublic void objectLocked(VM vm, ThreadInfo currentThread, ElementInfo lockedObject)
VMListenerobjectLocked in interface VMListenerpublic void objectUnlocked(VM vm, ThreadInfo currentThread, ElementInfo unlockedObject)
VMListenerobjectUnlocked in interface VMListenerpublic void objectWait(VM vm, ThreadInfo currentThread, ElementInfo waitingObject)
VMListenerobjectWait in interface VMListenerpublic void objectNotify(VM vm, ThreadInfo currentThread, ElementInfo notifyingObject)
VMListenerobjectNotify in interface VMListenerpublic void objectNotifyAll(VM vm, ThreadInfo currentThread, ElementInfo notifyingObject)
VMListenerobjectNotifyAll in interface VMListenerpublic void gcBegin(VM vm)
gcBegin in interface VMListenerpublic void gcEnd(VM vm)
gcEnd in interface VMListenerpublic void exceptionThrown(VM vm, ThreadInfo currentThread, ElementInfo thrownException)
VMListenerexceptionThrown in interface VMListenerpublic void exceptionBailout(VM vm, ThreadInfo currentThread)
VMListenerexceptionBailout in interface VMListenerpublic void exceptionHandled(VM vm, ThreadInfo currentThread)
VMListenerexceptionHandled in interface VMListenerpublic void choiceGeneratorRegistered(VM vm, ChoiceGenerator<?> nextCG, ThreadInfo currentThread, Instruction executedInstruction)
VMListenerchoiceGeneratorRegistered in interface VMListenerpublic void choiceGeneratorSet(VM vm, ChoiceGenerator<?> newCG)
VMListenerchoiceGeneratorSet in interface VMListenerpublic void choiceGeneratorAdvanced(VM vm, ChoiceGenerator<?> currentCG)
VMListenerchoiceGeneratorAdvanced in interface VMListenerpublic void choiceGeneratorProcessed(VM vm, ChoiceGenerator<?> processedCG)
VMListenerchoiceGeneratorProcessed in interface VMListenerpublic void methodEntered(VM vm, ThreadInfo currentThread, MethodInfo enteredMethod)
VMListenermethodEntered in interface VMListenerpublic void methodExited(VM vm, ThreadInfo currentThread, MethodInfo exitedMethod)
VMListenermethodExited in interface VMListenerpublic void stateAdvanced(Search search)
SearchListenerstateAdvanced in interface SearchListenerpublic void stateProcessed(Search search)
SearchListenerstateProcessed in interface SearchListenerpublic void stateBacktracked(Search search)
SearchListenerstateBacktracked in interface SearchListenerpublic void statePurged(Search search)
SearchListenerstatePurged in interface SearchListenerpublic void stateStored(Search search)
SearchListenerstateStored in interface SearchListenerpublic void stateRestored(Search search)
SearchListenerstateRestored in interface SearchListenerpublic void propertyViolated(Search search)
SearchListenerpropertyViolated in interface SearchListenerpublic void searchStarted(Search search)
SearchListenersearchStarted in interface SearchListenerpublic void searchConstraintHit(Search search)
SearchListenersearchConstraintHit in interface SearchListenerpublic void searchFinished(Search search)
SearchListenersearchFinished in interface SearchListenerpublic void publishStart(Publisher publisher)
publishStart in interface PublisherExtensionpublic void publishTransition(Publisher publisher)
publishTransition in interface PublisherExtensionpublic void publishPropertyViolation(Publisher publisher)
publishPropertyViolation in interface PublisherExtensionpublic void publishConstraintHit(Publisher publisher)
publishConstraintHit in interface PublisherExtensionpublic void publishFinished(Publisher publisher)
publishFinished in interface PublisherExtension