Package jason.infra.jade
Class JadeRuntimeServices
java.lang.Object
jason.infra.jade.JadeRuntimeServices
- All Implemented Interfaces:
RuntimeServices,Remote
-
Method Summary
Modifier and TypeMethodDescriptioncreateAgent(String agName, String agSource, String agClass, List<String> archClasses, ClassParameters bbPars, Settings stts, Agent father) Creates a new agent with agName from source agSource, using agClass as agent class (default value is "jason.asSemantics.Agent"), archClasses as agent architecture classes, bbPars as the belief base class (default value is "DefaultBeliefBase"), stts as Settings (default value is new Settings()), and father is the agent creating this agent (null is none).voiddfDeRegister(String agName, String service, String type) voiddfRegister(String agName, String service, String type) voiddfSubscribe(String agName, String service, String type) Returns a set of all agents' nameintGets the number of agents in the MAS.getNewAgentName(String baseName) booleanbooleanKills the agent named agName as a requested by byAg.voidregisterDefaultAgArch(String agArch) register a class to be included as new agents archsvoidstartAgent(String agName) starts an agent (e.g.voidstopMAS(int deadline, boolean stopJVM, int exitValue) Stops all MAS (the agents, the environment, the controller, ...)Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface jason.runtime.RuntimeServices
clone, getAgentSnapshot, getAgStatus, getDF, getMASName, getWP, loadASL, runAsAgent, stopMAS
-
Method Details
-
getNewAgentName
- Specified by:
getNewAgentNamein interfaceRuntimeServices
-
isRunning
public boolean isRunning()- Specified by:
isRunningin interfaceRuntimeServices
-
createAgent
public String createAgent(String agName, String agSource, String agClass, List<String> archClasses, ClassParameters bbPars, Settings stts, Agent father) throws Exception Description copied from interface:RuntimeServicesCreates a new agent with agName from source agSource, using agClass as agent class (default value is "jason.asSemantics.Agent"), archClasses as agent architecture classes, bbPars as the belief base class (default value is "DefaultBeliefBase"), stts as Settings (default value is new Settings()), and father is the agent creating this agent (null is none). if no archClasses is informed (null value), if fathers is informed use father's ag archs else use default ag archs (see registerDefaultAgArch)Example: createAgent("bob", "bob.asl", "mypkg.MyAgent", null, null, null); Returns the name of the agent
- Specified by:
createAgentin interfaceRuntimeServices- Throws:
Exception
-
startAgent
Description copied from interface:RuntimeServicesstarts an agent (e.g. create thread for it)- Specified by:
startAgentin interfaceRuntimeServices
-
getAgentsName
Description copied from interface:RuntimeServicesReturns a set of all agents' name- Specified by:
getAgentsNamein interfaceRuntimeServices
-
getAgentsQty
public int getAgentsQty()Description copied from interface:RuntimeServicesGets the number of agents in the MAS.- Specified by:
getAgentsQtyin interfaceRuntimeServices
-
killAgent
Description copied from interface:RuntimeServicesKills the agent named agName as a requested by byAg. Agent.stopAg() method is called before the agent is removed.- Specified by:
killAgentin interfaceRuntimeServices
-
stopMAS
Description copied from interface:RuntimeServicesStops all MAS (the agents, the environment, the controller, ...)- Specified by:
stopMASin interfaceRuntimeServices- Throws:
Exception
-
dfRegister
- Specified by:
dfRegisterin interfaceRuntimeServices
-
dfDeRegister
- Specified by:
dfDeRegisterin interfaceRuntimeServices
-
dfSearch
- Specified by:
dfSearchin interfaceRuntimeServices
-
dfSubscribe
- Specified by:
dfSubscribein interfaceRuntimeServices
-
registerDefaultAgArch
Description copied from interface:RuntimeServicesregister a class to be included as new agents archs- Specified by:
registerDefaultAgArchin interfaceRuntimeServices
-
getDefaultAgArchs
- Specified by:
getDefaultAgArchsin interfaceRuntimeServices
-