massim.gridsimulations
Class AbstractGridSimulation
java.lang.Object
massim.framework.DefaultSimulation
massim.framework.simulation.AbstractSimulation
massim.framework.simulation.ParallelizedRandomOrderSimulation
massim.gridsimulations.AbstractGridSimulation
- All Implemented Interfaces:
- Component, Simulation
- Direct Known Subclasses:
- GridSimulation, GridSimulation, GridSimulation, GridSimulation, GridSimulation
public abstract class AbstractGridSimulation
- extends ParallelizedRandomOrderSimulation
This class is the mainclass of the GridSimulation. It provides methods to
handle the initialization, configuration, presimulationstep and
postsimulationstep.
Method Summary |
java.lang.String |
finalizeSimpleSimulation()
This method is supposed to make final actions before the simulation is shut down. |
void |
preSimulationStep()
This method is supposed to make necessary changes to the world that must occur before
agents act in that step. |
void |
runAgents()
This method is supposed to let agents act. |
void |
simulationStep()
|
protected org.w3c.dom.Document |
updateAgentPosition(org.w3c.dom.Document doc)
|
Methods inherited from class massim.framework.simulation.AbstractSimulation |
configureSimulation, endSimulation, getAgents, getSimpleSimulationState, getSimulationState, getSteps, initializeSimpleSimulation, postSimulationStep, setSteps, startSimulation, stepSimulation |
Methods inherited from class massim.framework.DefaultSimulation |
concurrentCreateAgent, concurrentGetAction, createAgent, getAction, getAgentManager, getController, removeAgent, removeAllAgents, setAgentManager, setController, start, stop |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractGridSimulation
public AbstractGridSimulation()
preSimulationStep
public void preSimulationStep()
- Description copied from class:
AbstractSimulation
- This method is supposed to make necessary changes to the world that must occur before
agents act in that step.
- Specified by:
preSimulationStep
in class AbstractSimulation
runAgents
public void runAgents()
- Description copied from class:
AbstractSimulation
- This method is supposed to let agents act.
- Overrides:
runAgents
in class ParallelizedRandomOrderSimulation
simulationStep
public void simulationStep()
- Specified by:
simulationStep
in class AbstractSimulation
finalizeSimpleSimulation
public java.lang.String finalizeSimpleSimulation()
- Description copied from class:
AbstractSimulation
- This method is supposed to make final actions before the simulation is shut down. Agents are still available in this
method.
- Specified by:
finalizeSimpleSimulation
in class AbstractSimulation
updateAgentPosition
protected org.w3c.dom.Document updateAgentPosition(org.w3c.dom.Document doc)
Copyright © 2012. All Rights Reserved.