public class MaestroMonitor extends Object
Constructor and Description |
---|
MaestroMonitor(Predicate object)
Constructs a Monitor using the given predicate (ie.: note instanceof TestSuccessfulNotification)
|
Modifier and Type | Method and Description |
---|---|
void |
doLock()
Lock the execution
|
void |
doLock(long timeout)
Lock the execution
|
void |
doUnlock()
Unlock the execution
|
boolean |
shouldAwake(Object subject)
Tests if a subject matches the predicate
|
public MaestroMonitor(Predicate object)
object
- the monitoring predicatepublic void doLock() throws InterruptedException
InterruptedException
- if interruptedpublic void doLock(long timeout) throws InterruptedException
InterruptedException
- if interruptedpublic void doUnlock()
public boolean shouldAwake(Object subject)
subject
- the subject to test (ie.: a new note arriving on the collector)This documentation was released into the public domain.