akka.routing
Interface SmallestMailboxLike

All Known Implementing Classes:
SmallestMailboxRouter

public interface SmallestMailboxLike

The core pieces of the routing logic is located in this trait to be able to extend.


Method Summary
 scala.PartialFunction<scala.Tuple2<ActorRef,java.lang.Object>,scala.collection.immutable.Iterable<Destination>> createRoute(RouteeProvider routeeProvider)
           
 boolean hasMessages(ActorRef a)
          Returns true if the actor currently has any pending messages in the mailbox, i.e.
 boolean isProcessingMessage(ActorRef a)
          Returns true if the actor is currently processing a message.
 boolean isSuspended(ActorRef a)
          Returns true if the actor is currently suspended.
 int nrOfInstances()
           
 int numberOfMessages(ActorRef a)
          Returns the number of pending messages in the mailbox of the actor.
 scala.collection.immutable.Iterable<java.lang.String> routees()
           
 

Method Detail

nrOfInstances

int nrOfInstances()

routees

scala.collection.immutable.Iterable<java.lang.String> routees()

isProcessingMessage

boolean isProcessingMessage(ActorRef a)
Returns true if the actor is currently processing a message. It will always return false for remote actors. Method is exposed to subclasses to be able to implement custom routers based on mailbox and actor internal state.


hasMessages

boolean hasMessages(ActorRef a)
Returns true if the actor currently has any pending messages in the mailbox, i.e. the mailbox is not empty. It will always return false for remote actors. Method is exposed to subclasses to be able to implement custom routers based on mailbox and actor internal state.


isSuspended

boolean isSuspended(ActorRef a)
Returns true if the actor is currently suspended. It will always return false for remote actors. Method is exposed to subclasses to be able to implement custom routers based on mailbox and actor internal state.


numberOfMessages

int numberOfMessages(ActorRef a)
Returns the number of pending messages in the mailbox of the actor. It will always return 0 for remote actors. Method is exposed to subclasses to be able to implement custom routers based on mailbox and actor internal state.


createRoute

scala.PartialFunction<scala.Tuple2<ActorRef,java.lang.Object>,scala.collection.immutable.Iterable<Destination>> createRoute(RouteeProvider routeeProvider)