unsw.cse.mica.agent.transport
Class XMLAgentProtocol
java.lang.Object
unsw.cse.mica.agent.transport.AbstractAgentProtocol
unsw.cse.mica.agent.transport.XMLAgentProtocol
- All Implemented Interfaces:
- AgentActions, MessageHandler, AgentProtocol
- Direct Known Subclasses:
- SecureXMLAgentProtocol
public class XMLAgentProtocol
- extends AbstractAgentProtocol
An implementation of AgentProtocol
that uses XML to communicate with the blackboard.
- Author:
- jhw
- See Also:
XMLBlackboardProtocol
Methods inherited from class unsw.cse.mica.agent.transport.AbstractAgentProtocol |
deleteMob, getTypeManager, handleDeletedMob, handleNewMob, handleReplacedMob, handleTypeManagerChanged, mobSearch, readMob, register, replaceMob, setConnection, setMessageHandler, unregister, writeMob |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XMLAgentProtocol
public XMLAgentProtocol()
isConnected
public boolean isConnected()
- Description copied from interface:
AgentProtocol
- See if the protocol is currently connected?
- Returns:
- true if the protocol is connected, false otherwise
connect
public java.lang.String connect(java.lang.String proposedName)
throws TransportException
- Description copied from interface:
AgentActions
- Connect to the blackboard. This should be the first action performed by an agent.
- Parameters:
proposedName
- The agent name proposed by the agent.
- Returns:
- The actual agent name (usually the requested name with a suffix)
- Throws:
TransportException
disconnect
public void disconnect()
throws TransportException
- Description copied from interface:
AgentActions
- Disconnect from the Blackboard
- Throws:
TransportException
setStatusReply
public void setStatusReply(java.lang.String status)
setConnectReply
public void setConnectReply(java.lang.String agentName)
setWriteMobReply
public void setWriteMobReply(java.lang.String mobName)
setReadMobReply
public void setReadMobReply(java.lang.String status,
Mob mob)
setMobSearchReply
public void setMobSearchReply(java.util.List mobs)
setTypeManagerReply
public void setTypeManagerReply(TypeManager tm)