Package akka.testkit
Class TestFSMRef<S,D,T extends Actor>
- java.lang.Object
-
- akka.actor.ActorRef
-
- akka.actor.InternalActorRef
-
- akka.actor.ActorRefWithCell
-
- akka.actor.LocalActorRef
-
- akka.testkit.TestActorRef<T>
-
- akka.testkit.TestFSMRef<S,D,T>
-
- All Implemented Interfaces:
ActorRefScope
,LocalRef
,ScalaActorRef
,java.io.Serializable
,java.lang.Comparable<ActorRef>
,scala.Serializable
public class TestFSMRef<S,D,T extends Actor> extends TestActorRef<T>
Get current state name of this FSM.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description TestFSMRef(ActorSystem system, Props props, ActorRef supervisor, java.lang.String name, scala.Predef.$less$colon$less<T,FSM<S,D>> ev)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <S,D,T extends Actor>
TestFSMRef<S,D,T>apply(scala.Function0<T> factory, ActorRef supervisor, java.lang.String name, scala.reflect.ClassTag<T> evidence$3, scala.Predef.$less$colon$less<T,FSM<S,D>> ev, ActorSystem system)
static <S,D,T extends Actor>
TestFSMRef<S,D,T>apply(scala.Function0<T> factory, ActorRef supervisor, scala.reflect.ClassTag<T> evidence$4, scala.Predef.$less$colon$less<T,FSM<S,D>> ev, ActorSystem system)
static <S,D,T extends Actor>
TestFSMRef<S,D,T>apply(scala.Function0<T> factory, java.lang.String name, scala.reflect.ClassTag<T> evidence$2, scala.Predef.$less$colon$less<T,FSM<S,D>> ev, ActorSystem system)
static <S,D,T extends Actor>
TestFSMRef<S,D,T>apply(scala.Function0<T> factory, scala.reflect.ClassTag<T> evidence$1, scala.Predef.$less$colon$less<T,FSM<S,D>> ev, ActorSystem system)
void
cancelTimer(java.lang.String name)
Proxy forFSM.cancelTimer(java.lang.String)
.boolean
isStateTimerActive()
Proxy forFSM.isStateTimerActive()
.boolean
isTimerActive(java.lang.String name)
Proxy forFSM.isStateTimerActive()
.void
setState(S stateName, D stateData, scala.concurrent.duration.FiniteDuration timeout, scala.Option<FSM.Reason> stopReason)
Change FSM state; any value left out defaults to the current FSM state (timeout defaults to None).S
setState$default$1()
D
setState$default$2()
scala.concurrent.duration.FiniteDuration
setState$default$3()
scala.Option<FSM.Reason>
setState$default$4()
void
setTimer(java.lang.String name, java.lang.Object msg, scala.concurrent.duration.FiniteDuration timeout, boolean repeat)
boolean
setTimer$default$4()
D
stateData()
Get current state data of this FSM.S
stateName()
Get current state name of this FSM.-
Methods inherited from class akka.testkit.TestActorRef
apply, apply, apply, apply, apply, apply, apply, apply, apply, apply, create, create, create, create, dispatcher, newActorCell, props, randomName, receive, receive, toString, underlyingActor, unwatch, watch
-
Methods inherited from class akka.actor.LocalActorRef
$bang, $bang$default$2, actorContext, children, getChild, getParent, getSingleChild, isTerminated, path, provider, restart, resume, sendSystemMessage, start, stop, suspend, underlying, writeReplace
-
Methods inherited from class akka.actor.InternalActorRef
isLocal
-
Methods inherited from class akka.actor.ActorRef
compareTo, equals, forward, hashCode, noSender, tell
-
-
-
-
Method Detail
-
apply
public static <S,D,T extends Actor> TestFSMRef<S,D,T> apply(scala.Function0<T> factory, scala.reflect.ClassTag<T> evidence$1, scala.Predef.$less$colon$less<T,FSM<S,D>> ev, ActorSystem system)
-
apply
public static <S,D,T extends Actor> TestFSMRef<S,D,T> apply(scala.Function0<T> factory, java.lang.String name, scala.reflect.ClassTag<T> evidence$2, scala.Predef.$less$colon$less<T,FSM<S,D>> ev, ActorSystem system)
-
apply
public static <S,D,T extends Actor> TestFSMRef<S,D,T> apply(scala.Function0<T> factory, ActorRef supervisor, java.lang.String name, scala.reflect.ClassTag<T> evidence$3, scala.Predef.$less$colon$less<T,FSM<S,D>> ev, ActorSystem system)
-
apply
public static <S,D,T extends Actor> TestFSMRef<S,D,T> apply(scala.Function0<T> factory, ActorRef supervisor, scala.reflect.ClassTag<T> evidence$4, scala.Predef.$less$colon$less<T,FSM<S,D>> ev, ActorSystem system)
-
stateName
public S stateName()
Get current state name of this FSM.- Returns:
- (undocumented)
-
stateData
public D stateData()
Get current state data of this FSM.- Returns:
- (undocumented)
-
setState
public void setState(S stateName, D stateData, scala.concurrent.duration.FiniteDuration timeout, scala.Option<FSM.Reason> stopReason)
Change FSM state; any value left out defaults to the current FSM state (timeout defaults to None). This method is directly equivalent to a corresponding transition initiated from within the FSM, including timeout and stop handling.- Parameters:
stateName
- (undocumented)stateData
- (undocumented)timeout
- (undocumented)stopReason
- (undocumented)
-
setState$default$1
public S setState$default$1()
-
setState$default$2
public D setState$default$2()
-
setState$default$3
public scala.concurrent.duration.FiniteDuration setState$default$3()
-
setState$default$4
public scala.Option<FSM.Reason> setState$default$4()
-
setTimer
public void setTimer(java.lang.String name, java.lang.Object msg, scala.concurrent.duration.FiniteDuration timeout, boolean repeat)
Proxy forFSM.setTimer(java.lang.String, java.lang.Object, scala.concurrent.duration.FiniteDuration, boolean)
.- Parameters:
name
- (undocumented)msg
- (undocumented)timeout
- (undocumented)repeat
- (undocumented)
-
setTimer$default$4
public boolean setTimer$default$4()
-
cancelTimer
public void cancelTimer(java.lang.String name)
Proxy forFSM.cancelTimer(java.lang.String)
.- Parameters:
name
- (undocumented)
-
isTimerActive
public boolean isTimerActive(java.lang.String name)
Proxy forFSM.isStateTimerActive()
.- Parameters:
name
- (undocumented)- Returns:
- (undocumented)
-
isStateTimerActive
public boolean isStateTimerActive()
Proxy forFSM.isStateTimerActive()
.- Returns:
- (undocumented)
-
-