S
- the type of stateE
- the type of eventpublic interface Trigger<S,E>
Trigger
is the cause of the Transition
. Cause is usually an
event but can be some other signal or a change in some condition.Modifier and Type | Method and Description |
---|---|
void |
addTriggerListener(TriggerListener listener)
Adds the trigger listener.
|
void |
arm()
Arm a trigger.
|
void |
disarm()
Disarm a trigger.
|
reactor.core.publisher.Mono<java.lang.Boolean> |
evaluate(TriggerContext<S,E> context)
Evaluate trigger.
|
E |
getEvent()
Gets the event associated with this trigger.
|
reactor.core.publisher.Mono<java.lang.Boolean> evaluate(TriggerContext<S,E> context)
context
- the contextvoid addTriggerListener(TriggerListener listener)
listener
- the listenerE getEvent()
void arm()
TriggerListener
may receive events.void disarm()
TriggerListener
will not receive events.