com.caucho.amp.impl
Class HashMapAmpBroker

java.lang.Object
  extended by com.caucho.amp.broker.AbstractAmpBroker
      extended by com.caucho.amp.impl.HashMapAmpBroker
All Implemented Interfaces:
AmpBroker

public class HashMapAmpBroker
extends AbstractAmpBroker

AmpRouter routes messages to mailboxes.


Constructor Summary
HashMapAmpBroker()
           
 
Method Summary
 AmpActorRef addMailbox(java.lang.String address, AmpMailbox mailbox)
          Adds a mailbox (optional operation).
 AmpActorRef getActorRef(java.lang.String address)
          Returns a mailbox for the given address, or null if the mailbox does not exist.
protected  AmpMailbox getMailbox(java.lang.String address)
           
 
Methods inherited from class com.caucho.amp.broker.AbstractAmpBroker
close, getBrokerActor, query, removeMailbox, reply, send
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HashMapAmpBroker

public HashMapAmpBroker()
Method Detail

getActorRef

public AmpActorRef getActorRef(java.lang.String address)
Description copied from interface: AmpBroker
Returns a mailbox for the given address, or null if the mailbox does not exist.

Specified by:
getActorRef in interface AmpBroker
Overrides:
getActorRef in class AbstractAmpBroker
Parameters:
address - the address of the mailbox
Returns:
the mailbox with the given address or null

addMailbox

public AmpActorRef addMailbox(java.lang.String address,
                              AmpMailbox mailbox)
Description copied from interface: AmpBroker
Adds a mailbox (optional operation).

Specified by:
addMailbox in interface AmpBroker
Overrides:
addMailbox in class AbstractAmpBroker

getMailbox

protected AmpMailbox getMailbox(java.lang.String address)