|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectmassim.framework.simulation.AbstractSimulationAgent
massim.competition2011.GraphSimulationAgent
public class GraphSimulationAgent
This class deals with the agent state, his actions and perceptions.
Constructor Summary | |
---|---|
GraphSimulationAgent()
The constructor instantiates the agentstate and the action |
Method Summary | |
---|---|
FinalPerception |
createFinalPerception(WorldState simstate,
AgentState[] agentstates)
|
InitialStickyPerception |
createInitialPerception(WorldState simstate,
AgentState[] agentstates)
|
Perception |
createPerception(WorldState simstate,
AgentState[] agentstates)
This method only calculates private agent perceptions. |
AgentState |
getAgentState()
Retrieve agent state. |
void |
initialize(GraphSimulationConfiguration config)
Initializes the agent internal values. |
void |
processAction(Action a,
WorldState simstate,
AgentState[] agentstates)
|
void |
setAction(Action newAction)
Sets the action received from the client-side agent to the agent state, for execution in the current step. |
void |
setAgentParameter(AgentParameter agentpar)
Configures the agent according to the AgentParameter as parsed from the configuration file. |
Methods inherited from class massim.framework.simulation.AbstractSimulationAgent |
---|
getAgent, setAgent |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public GraphSimulationAgent()
Method Detail |
---|
public void setAgentParameter(AgentParameter agentpar)
AgentParameter
as parsed from the configuration file.
agentpar
must be an instance of GraphSimulationAgentParameter
. The information
included in agentpar
is the name of the agent, the name of its role, and the name of its team
setAgentParameter
in interface SimulationAgent
setAgentParameter
in class AbstractSimulationAgent
agentpar
- agent parameters to usepublic void initialize(GraphSimulationConfiguration config)
AgentParameter
must have been set previously,
by calling setAgentParameter
.
config
- the current configuration being usedpublic AgentState getAgentState()
SimulationAgent
public Perception createPerception(WorldState simstate, AgentState[] agentstates)
public void processAction(Action a, WorldState simstate, AgentState[] agentstates)
public InitialStickyPerception createInitialPerception(WorldState simstate, AgentState[] agentstates)
public FinalPerception createFinalPerception(WorldState simstate, AgentState[] agentstates)
public void setAction(Action newAction)
newAction
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |