T
- the type of the event that is trackedpublic interface TriggerPolicy<T,S>
Modifier and Type | Method and Description |
---|---|
S |
getState()
Return runtime state to be checkpointed by the framework for restoring the trigger
policy in case of failures.
|
void |
reset()
resets the trigger policy.
|
void |
restoreState(S state)
Restore the trigger policy from the state that was earlier checkpointed by the framework.
|
void |
shutdown()
Any clean up could be handled here.
|
void |
start()
Starts the trigger policy.
|
void |
track(Event<T> event)
Tracks the event and could use this to invoke the trigger.
|
void track(Event<T> event)
event
- the input eventvoid reset()
void start()
void shutdown()
S getState()
void restoreState(S state)
state
- the state