Package jade.core.management
Interface AgentManagementSlice
-
- All Superinterfaces:
Serializable,Serializable,Service.Slice
- All Known Implementing Classes:
AgentManagementProxy
public interface AgentManagementSlice extends Service.Slice
The horizontal interface for the JADE kernel-level service managing the basic agent life cycle: creation, destruction, suspension and resumption.- Author:
- Giovanni Rimassa - FRAMeTech s.r.l.
-
-
Field Summary
Fields Modifier and Type Field Description static StringADD_TOOLThis command name represents the action of adding a new tool to the platform.static booleanCREATE_AND_STARTstatic booleanCREATE_ONLYstatic StringH_BORNAGENTstatic StringH_CHANGEAGENTSTATEstatic StringH_CREATEAGENTstatic StringH_DEADAGENTstatic StringH_EXITCONTAINERstatic StringH_KILLAGENTstatic StringH_RESUMEDAGENTstatic StringH_SUSPENDEDAGENTstatic StringINFORM_CREATEDThis command is issued by an agent that has just been created, and causes JADE runtime to actually start up the agent thread.static StringINFORM_KILLEDThis command is issued by an agent that has just been destroyed and whose thread is terminating.static StringINFORM_STATE_CHANGEDThis command is issued by an agent that has just changed its life-cycle state.static StringKILL_CONTAINERThis command name represents thekill-containeraction.static StringNAMEThe name of this service.static StringREMOVE_TOOLThis command name represents the action of removing an existing tool from the platform.static StringREQUEST_CREATEThis command name represents thecreate-agentaction.static StringREQUEST_KILLThis command name represents thekill-agentaction.static StringREQUEST_STATE_CHANGEThis command name represents all agent management actions requesting a change in the life cycle state of their target agent (suspend, resume, etc.).static StringSHUTDOWN_PLATFORMThis command name represents theshutdown-platformaction.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidbornAgent(AID name, ContainerID cid, Command sourceCmd)voidchangeAgentState(AID agentID, int newState)voidcreateAgent(AID agentID, String className, Object[] arguments, JADEPrincipal owner, Credentials initialCredentials, boolean startIt, Command sourceCmd)voiddeadAgent(AID name, Command sourceCmd)voidexitContainer()voidkillAgent(AID agentID, Command sourceCmd)voidresumedAgent(AID name)voidsuspendedAgent(AID name)-
Methods inherited from interface jade.core.Service.Slice
getNode, getService, serve
-
-
-
-
Field Detail
-
NAME
static final String NAME
The name of this service.- See Also:
- Constant Field Values
-
REQUEST_CREATE
static final String REQUEST_CREATE
This command name represents thecreate-agentaction. The target agent identifier in this command is set tonull, because no agent exists yet. This command object represents only the first half of the complete agent creation process. Even if this command is accepted by the kernel, there is no guarantee that the requested creation will ever happen. Only when theInformCreatedcommand is issued can one assume that the agent creation has taken place.- See Also:
- Constant Field Values
-
REQUEST_KILL
static final String REQUEST_KILL
This command name represents thekill-agentaction. This command object represents only the first half of the complete agent destruction process. Even if this command is accepted by the kernel, there is no guarantee that the requested destruction will ever happen. Only when theInformKilledcommand is issued can one assume that the agent destruction has taken place.- See Also:
- Constant Field Values
-
REQUEST_STATE_CHANGE
static final String REQUEST_STATE_CHANGE
This command name represents all agent management actions requesting a change in the life cycle state of their target agent (suspend, resume, etc.). This command object represents only the first half of the complete agent state change process. Even if this command is accepted by the kernel, there is no guarantee that the requested state change will ever happen. Only when theInformStateChangedcommand is issued can one assume that the state change has taken place.- See Also:
- Constant Field Values
-
INFORM_CREATED
static final String INFORM_CREATED
This command is issued by an agent that has just been created, and causes JADE runtime to actually start up the agent thread. The agent creation can be the outcome of a previously issuedRequestCreatecommand. In that case, this command represents only the second half of the complete agent creation process.- See Also:
- Constant Field Values
-
INFORM_KILLED
static final String INFORM_KILLED
This command is issued by an agent that has just been destroyed and whose thread is terminating. The agent destruction can either be an autonomous move of the agent or the outcome of a previously issuedRequestKillcommand. In the second case, this command represents only the second half of the complete agent destruction process.- See Also:
- Constant Field Values
-
INFORM_STATE_CHANGED
static final String INFORM_STATE_CHANGED
This command is issued by an agent that has just changed its life-cycle state. The agent state change can either be an autonomous move of the agent or the outcome of a previously issuedRequestStateChangecommand. In that case, this command represents only the second half of the complete agent state tansition process.- See Also:
- Constant Field Values
-
SHUTDOWN_PLATFORM
static final String SHUTDOWN_PLATFORM
This command name represents theshutdown-platformaction. This command has no effect but informing interested services that the platform shutdown process is starting.- See Also:
- Constant Field Values
-
KILL_CONTAINER
static final String KILL_CONTAINER
This command name represents thekill-containeraction.- See Also:
- Constant Field Values
-
ADD_TOOL
static final String ADD_TOOL
This command name represents the action of adding a new tool to the platform.- See Also:
- Constant Field Values
-
REMOVE_TOOL
static final String REMOVE_TOOL
This command name represents the action of removing an existing tool from the platform.- See Also:
- Constant Field Values
-
CREATE_AND_START
static final boolean CREATE_AND_START
- See Also:
- Constant Field Values
-
CREATE_ONLY
static final boolean CREATE_ONLY
- See Also:
- Constant Field Values
-
H_CREATEAGENT
static final String H_CREATEAGENT
- See Also:
- Constant Field Values
-
H_KILLAGENT
static final String H_KILLAGENT
- See Also:
- Constant Field Values
-
H_CHANGEAGENTSTATE
static final String H_CHANGEAGENTSTATE
- See Also:
- Constant Field Values
-
H_BORNAGENT
static final String H_BORNAGENT
- See Also:
- Constant Field Values
-
H_DEADAGENT
static final String H_DEADAGENT
- See Also:
- Constant Field Values
-
H_SUSPENDEDAGENT
static final String H_SUSPENDEDAGENT
- See Also:
- Constant Field Values
-
H_RESUMEDAGENT
static final String H_RESUMEDAGENT
- See Also:
- Constant Field Values
-
H_EXITCONTAINER
static final String H_EXITCONTAINER
- See Also:
- Constant Field Values
-
-
Method Detail
-
createAgent
void createAgent(AID agentID, String className, Object[] arguments, JADEPrincipal owner, Credentials initialCredentials, boolean startIt, Command sourceCmd) throws IMTPException, NotFoundException, NameClashException, JADESecurityException
-
killAgent
void killAgent(AID agentID, Command sourceCmd) throws IMTPException, NotFoundException
- Throws:
IMTPExceptionNotFoundException
-
changeAgentState
void changeAgentState(AID agentID, int newState) throws IMTPException, NotFoundException
- Throws:
IMTPExceptionNotFoundException
-
bornAgent
void bornAgent(AID name, ContainerID cid, Command sourceCmd) throws IMTPException, NameClashException, NotFoundException, JADESecurityException
-
deadAgent
void deadAgent(AID name, Command sourceCmd) throws IMTPException, NotFoundException
- Throws:
IMTPExceptionNotFoundException
-
suspendedAgent
void suspendedAgent(AID name) throws IMTPException, NotFoundException
- Throws:
IMTPExceptionNotFoundException
-
resumedAgent
void resumedAgent(AID name) throws IMTPException, NotFoundException
- Throws:
IMTPExceptionNotFoundException
-
exitContainer
void exitContainer() throws IMTPException, NotFoundException- Throws:
IMTPExceptionNotFoundException
-
-