Class ExtractRoute

  extended by akka.testkit.ExtractRoute

public class ExtractRoute
extends java.lang.Object

This object can be used to extract the Route out of a RoutedActorRef. These are the refs which represent actors created from Props having a RouterConfig. Use this extractor if you want to test the routing directly, i.e. without actually dispatching messages.

 val router = system.actorOf(Props[...].withRouter(new MyRouter))
 val route = ExtractRoute(router)
 route(sender -> message) must be(...)

Constructor Summary
Method Summary
static scala.PartialFunction<scala.Tuple2<ActorRef,java.lang.Object>,scala.collection.immutable.Iterable<Destination>> apply(ActorRef ref)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail


public ExtractRoute()
Method Detail


public static scala.PartialFunction<scala.Tuple2<ActorRef,java.lang.Object>,scala.collection.immutable.Iterable<Destination>> apply(ActorRef ref)