public class TimerWithinOrMaxCountGuard extends java.lang.Object implements Guard, ScheduleHandleCallback
MatchedEventMap
instances pass until then.Constructor and Description |
---|
TimerWithinOrMaxCountGuard(long msec,
int numCountTo,
Quitable quitable)
Ctor.
|
Modifier and Type | Method and Description |
---|---|
void |
accept(EventGuardVisitor visitor) |
boolean |
inspect(MatchedEventMap matchEvent)
Returns true if inspection shows that the match events can pass, or false to not pass.
|
void |
scheduledTrigger(ExtensionServicesContext extensionServicesContext)
Callback that is invoked as indicated by a schedule added to the scheduling service.
|
void |
startGuard()
Start the guard operation.
|
void |
stopGuard()
Called when sub-expression quits, or when the pattern stopped.
|
public TimerWithinOrMaxCountGuard(long msec, int numCountTo, Quitable quitable)
msec
- - number of millisecond to guard expirationnumCountTo
- - max number of countsquitable
- - to use to indicate that the gaurd quittedpublic void startGuard()
Guard
startGuard
in interface Guard
public boolean inspect(MatchedEventMap matchEvent)
Guard
public void stopGuard()
Guard
public void scheduledTrigger(ExtensionServicesContext extensionServicesContext)
ScheduleHandleCallback
scheduledTrigger
in interface ScheduleHandleCallback
extensionServicesContext
- is a marker interface for providing custom extension services
passed to the triggered classpublic void accept(EventGuardVisitor visitor)