Package jade.tools.testagent
Class TestAgent
- java.lang.Object
-
- jade.core.Agent
-
- jade.tools.testagent.TestAgent
-
- All Implemented Interfaces:
TimerListener,Serializable,Serializable,Runnable
public class TestAgent extends Agent
This can be used as test agent for sending and receiving messages to the Agentplatform and Other agents. A couple of message templates are included in the menu.- Author:
- Chris van Aart - Acklin B.V., the Netherlands
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class jade.core.Agent
Agent.Interrupted
-
-
Field Summary
-
Fields inherited from class jade.core.Agent
AP_ACTIVE, AP_DELETED, AP_IDLE, AP_INITIATED, AP_MAX, AP_MIN, AP_SUSPENDED, AP_WAITING, D_ACTIVE, D_MAX, D_MIN, D_RETIRED, D_SUSPENDED, D_UNKNOWN, MSG_QUEUE_CLASS
-
-
Constructor Summary
Constructors Constructor Description TestAgent()Constructor for the TestAgent
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddoDeRegisterAMS()voiddoDeregisterDF()voiddoExit()exit methodvoiddoHelloWorld()Description of the MethodvoiddoLausannePing()voiddoLocalPing()voiddoNewMessage()Description of the MethodvoiddoRegisterAMS()Description of the MethodvoiddoRegisterDF()voiddoReply()voiddoSearchAMS()voiddoSearchDF()voiddoSystemOut()Description of the MethodACLMessagegetPlatformRequest()Gets the PlatformRequest attribute of the TestAgent objectstatic voidmain(String[] args)The main program for the TestAgent classvoidprocessIncomingMessage(ACLMessage msg)Description of the MethodvoidsendMessage()Description of the Methodprotected voidsetup()Description of the Method-
Methods inherited from class jade.core.Agent
addBehaviour, afterClone, afterMove, beforeClone, beforeMove, blockingReceive, blockingReceive, blockingReceive, blockingReceive, changeStateTo, clean, createMessageQueue, doActivate, doClone, doDelete, doMove, doSuspend, doTimeOut, doWait, doWait, doWake, getAgentState, getAID, getAID, getAMS, getArguments, getBehavioursCnt, getBootProperties, getContainerController, getContentManager, getCurQueueSize, getDefaultDF, getExecutedBehavioursCnt, getGenerateBehaviourEvents, getGenerateMessageEvents, getHap, getHelper, getLocalName, getName, getO2AInterface, getO2AObject, getPostedMessagesCnt, getProperty, getQueueSize, getReceivedMessagesCnt, getSentMessagesCnt, getState, here, isAlive, isRestarting, join, notifyChangeBehaviourState, notifyRestarted, postMessage, putBack, putO2AObject, receive, receive, receive, registerO2AInterface, removeBehaviour, removeTimer, restartLater, restoreBufferedState, restoreFields, run, send, setArguments, setEnabledO2ACommunication, setGenerateBehaviourEvents, setGenerateMessageEvents, setO2AManager, setQueueSize, takeDown, waitUntilStarted, write
-
-
-
-
Method Detail
-
main
public static void main(String[] args)
The main program for the TestAgent class- Parameters:
args- The command line arguments
-
getPlatformRequest
public ACLMessage getPlatformRequest()
Gets the PlatformRequest attribute of the TestAgent object- Returns:
- The PlatformRequest value
-
doRegisterAMS
public void doRegisterAMS()
Description of the Method
-
doRegisterDF
public void doRegisterDF()
-
doDeregisterDF
public void doDeregisterDF()
-
doDeRegisterAMS
public void doDeRegisterAMS()
-
doSearchAMS
public void doSearchAMS()
-
doSearchDF
public void doSearchDF()
-
doLausannePing
public void doLausannePing()
-
doLocalPing
public void doLocalPing()
-
doHelloWorld
public void doHelloWorld()
Description of the Method
-
doSystemOut
public void doSystemOut()
Description of the Method
-
doExit
public void doExit()
exit method
-
doNewMessage
public void doNewMessage()
Description of the Method
-
sendMessage
public void sendMessage()
Description of the Method
-
processIncomingMessage
public void processIncomingMessage(ACLMessage msg)
Description of the Method- Parameters:
msg- Description of Parameter
-
doReply
public void doReply()
-
setup
protected void setup()
Description of the Method- Overrides:
setupin classAgent- See Also:
Agent.addBehaviour(Behaviour b),Behaviour
-
-