Package akka.japi.pf
Class FSMTransitionHandlerBuilder<S>
- java.lang.Object
-
- akka.japi.pf.FSMTransitionHandlerBuilder<S>
-
- Type Parameters:
S
- the state type
public class FSMTransitionHandlerBuilder<S> extends java.lang.Object
Builder used to create a partial function forFSM.onTransition(scala.PartialFunction<scala.Tuple2<S, S>, scala.runtime.BoxedUnit>)
.
-
-
Constructor Summary
Constructors Constructor Description FSMTransitionHandlerBuilder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description scala.PartialFunction<scala.Tuple2<S,S>,scala.runtime.BoxedUnit>
build()
Build aPartialFunction
from this builder.FSMTransitionHandlerBuilder<S>
state(S fromState, S toState, FI.UnitApply2<S,S> apply)
Add a case statement that matches on a from state and a to state.FSMTransitionHandlerBuilder<S>
state(S fromState, S toState, FI.UnitApplyVoid apply)
Add a case statement that matches on a from state and a to state.
-
-
-
Method Detail
-
state
public FSMTransitionHandlerBuilder<S> state(S fromState, S toState, FI.UnitApplyVoid apply)
Add a case statement that matches on a from state and a to state.- Parameters:
fromState
- the from state to match on, or null for anytoState
- the to state to match on, or null for anyapply
- an action to apply when the states match- Returns:
- the builder with the case statement added
-
state
public FSMTransitionHandlerBuilder<S> state(S fromState, S toState, FI.UnitApply2<S,S> apply)
Add a case statement that matches on a from state and a to state.- Parameters:
fromState
- the from state to match on, or null for anytoState
- the to state to match on, or null for anyapply
- an action to apply when the states match- Returns:
- the builder with the case statement added
-
-