akka.actor
Interface UntypedActorContext

All Superinterfaces:
ActorContext, ActorRefFactory

public interface UntypedActorContext
extends ActorContext

UntypedActorContext is the UntypedActor equivalent of ActorContext, containing the Java API


Method Summary
 void become(Procedure<java.lang.Object> behavior)
          Changes the Actor's behavior to become the new 'Procedure' handler.
 void become(Procedure<java.lang.Object> behavior, boolean discardOld)
          Changes the Actor's behavior to become the new 'Procedure' handler.
 ActorRef getChild(java.lang.String name)
          Returns a reference to the named child or null if no child with that name exists.
 java.lang.Iterable<ActorRef> getChildren()
          Returns an unmodifiable Java Collection containing the linked actors, please note that the backing map is thread-safe but not immutable
 
Methods inherited from interface akka.actor.ActorContext
become, become, child, children, dispatcher, parent, props, receiveTimeout, self, sender, setReceiveTimeout, system, unbecome, unwatch, watch, writeObject
 
Methods inherited from interface akka.actor.ActorRefFactory
actorFor, actorFor, actorFor, actorFor, actorOf, actorOf, actorSelection, actorSelection, guardian, lookupRoot, provider, stop, systemImpl
 

Method Detail

getChildren

java.lang.Iterable<ActorRef> getChildren()
Returns an unmodifiable Java Collection containing the linked actors, please note that the backing map is thread-safe but not immutable


getChild

ActorRef getChild(java.lang.String name)
Returns a reference to the named child or null if no child with that name exists.


become

void become(Procedure<java.lang.Object> behavior)
Changes the Actor's behavior to become the new 'Procedure' handler. Replaces the current behavior on the top of the behavior stack.


become

void become(Procedure<java.lang.Object> behavior,
            boolean discardOld)
Changes the Actor's behavior to become the new 'Procedure' handler. This method acts upon the behavior stack as follows:

- if discardOld = true it will replace the top element (i.e. the current behavior) - if discardOld = false it will keep the current behavior and push the given one atop

The default of replacing the current behavior on the stack has been chosen to avoid memory leaks in case client code is written without consulting this documentation first (i.e. always pushing new behaviors and never issuing an unbecome())