All Packages Class Hierarchy This Package Previous Next Index
Class edu.cmu.paid.network.voyager.MulticastAgent
java.lang.Object
|
+----edu.cmu.paid.network.voyager.MulticastAgent
- public class MulticastAgent
- extends Object
- implements IMulticastAgent, Serializable
This is a local object container used to hold objects to be linked in a
multicasting network.
- Author:
- Barrett Trask
- See Also:
- IMulticastAgent
-
MulticastAgent()
- Constructor used to initialize the neighbors of this MulticastAgent.
-
MulticastAgent(MulticastAgent[])
- Constructor used to initialize the neighbors of this MulticastAgent.
-
add(Object)
- Function to add objects to agent to allow message delivery.
-
connect(IMulticastAgent)
- Create a connection to another MulticastAgent.
-
contains(Object)
- Check if an object is contained in this agent.
-
disconnect(IMulticastAgent)
- Delete a connection to another MulticastAgent.
-
getContents()
- Get an array of all objects contained by this agent.
-
getISubspace()
-
-
getSubspace()
-
-
isNeighbor(IMulticastAgent)
- Checks if the agent is connected.
-
multicast(String, Object[], String)
- Mutlicast to objects or interfaces contained within a set of interconnected
agents.
-
publish(EventObject, Topic)
- Publish an event on a given topic in a set of interconnected agents.
-
remove(Object)
- Function to remove objects from agent.
MulticastAgent
public MulticastAgent()
- Constructor used to initialize the neighbors of this MulticastAgent.
MulticastAgent
public MulticastAgent(MulticastAgent neighborList[])
- Constructor used to initialize the neighbors of this MulticastAgent.
- Parameters:
- neighborList - List of MulticastAgents to connect to this new agent.
connect
public void connect(IMulticastAgent newNeighbor)
- Create a connection to another MulticastAgent.
- Parameters:
- newNeighbor - The agent to make the new connection to.
disconnect
public void disconnect(IMulticastAgent oldNeighbor)
- Delete a connection to another MulticastAgent.
- Parameters:
- oldNeighbor - The neighboring agent to remove its connection.
isNeighbor
public boolean isNeighbor(IMulticastAgent agent)
- Checks if the agent is connected.
- Parameters:
- agent - The agent whose connection is being checked.
- Returns:
- True if the agent is a connected neighbor, false otherwise.
add
public void add(Object newObject)
- Function to add objects to agent to allow message delivery.
- Parameters:
- newObject - The reference to the object to be inserted into the agent.
remove
public void remove(Object oldObject)
- Function to remove objects from agent.
- Parameters:
- oldObject - An object within an agent to be removed.
getContents
public Object[] getContents()
- Get an array of all objects contained by this agent.
- Returns:
- An array of objects.
contains
public boolean contains(Object object)
- Check if an object is contained in this agent.
- Parameters:
- object - The object reference to check.
- Returns:
- True if the object is here, false otherwise.
multicast
public void multicast(String methodSig,
Object args[],
String className)
- Mutlicast to objects or interfaces contained within a set of interconnected
agents.
- Parameters:
- methodSig - The method name if unique. The entire signature with
parameter types specified in parentheses.
- args - An array of object to pass to the method as arguments.
- className - The name of a class or interface contained within an agent
publish
public void publish(EventObject event,
Topic topic)
- Publish an event on a given topic in a set of interconnected agents.
Only objects that implement the event listener interface will be able to
receive events.
- Parameters:
- event - A java event.
- topic - A hierarchical string, delineated with '.', of topic fields.
Wildcards '*' and "<" may be used. '*' matches for next field. '<'
matches for all remaining fields.
getSubspace
public Subspace getSubspace()
- Returns:
- The private subspace member.
getISubspace
public ISubspace getISubspace()
- Returns:
- A proxy of the private subspace member cast into an interface.
All Packages Class Hierarchy This Package Previous Next Index
This page is hosted by the Chair for Applied Software Engineering of the Technische Universität München.
Imprint (Impressum)