@Deprecated public abstract class AbstractEnvironment<AT extends Agent> extends Object implements Environment<AT>
Modifier and Type | Field and Description |
---|---|
protected org.arakhne.tinyMAS.core.AbstractEnvironment.EnvironmentClock |
_clock
Deprecated.
Simulation clock.
|
protected TimeManager |
_time_manager
Deprecated.
Unit used to compute the simulation time.
|
Constructor and Description |
---|
AbstractEnvironment(TimeManager time_manager)
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
SimulationClock |
getSimulationClock()
Deprecated.
Replies the clock used by the environment.
|
double |
getSimulationStepDuration()
Deprecated.
Replies the duration of a simulation loop for this environment.
|
double |
getSimulationStepDuration(TimeUnit desired_unit)
Deprecated.
Replies the duration of a simulation loop for this environment.
|
double |
getSimulationTime()
Deprecated.
Replies the current date of simulation.
|
double |
getSimulationTime(TimeUnit desired_unit)
Deprecated.
Replies the current date of simulation.
|
void |
init()
Deprecated.
Initialize this environment.
|
boolean |
isAlive()
Deprecated.
Replies if this environment is alive.
|
protected void |
killMe()
Deprecated.
Notify the kernel that this environment is requesting to be killed.
|
void |
postAgentScheduling(Kernel<AT,?,?,?> runningKernel)
Deprecated.
This function os called by the called after
the on scheduling step of the agents.
|
void |
preAgentScheduling(Kernel<AT,?,?,?> runningKernel)
Deprecated.
This function os called by the called before
the on scheduling step of the agents.
|
abstract void |
putAgent(AT agent)
Deprecated.
Put the given agent inside the environment.
|
abstract void |
removeAgent(AgentIdentifier agent)
Deprecated.
Remove the given agent from the environment.
|
void |
shutdown()
Deprecated.
Shutdown this environment.
|
protected final TimeManager _time_manager
protected final org.arakhne.tinyMAS.core.AbstractEnvironment.EnvironmentClock _clock
public AbstractEnvironment(TimeManager time_manager)
public boolean isAlive()
If the environment is not alive, the multiagent kernel will quit.
isAlive
in interface Environment<AT extends Agent>
protected void killMe()
When a situated environment desappear, all the agents inside will be killed also.
public void init()
init
in interface Environment<AT extends Agent>
public void shutdown()
shutdown
in interface Environment<AT extends Agent>
public abstract void putAgent(AT agent)
putAgent
in interface Environment<AT extends Agent>
public abstract void removeAgent(AgentIdentifier agent)
removeAgent
in interface Environment<AT extends Agent>
public void preAgentScheduling(Kernel<AT,?,?,?> runningKernel)
preAgentScheduling
in interface Environment<AT extends Agent>
runningKernel
- is the instance of the kernel that is running this environment.public void postAgentScheduling(Kernel<AT,?,?,?> runningKernel)
postAgentScheduling
in interface Environment<AT extends Agent>
runningKernel
- is the instance of the kernel that is running this environment.public final double getSimulationTime(TimeUnit desired_unit)
The unit depends on the environment's implementation.
desired_unit
- indicates the unit to usepublic final double getSimulationTime()
The unit depends on the environment's implementation.
public final double getSimulationStepDuration(TimeUnit desired_unit)
desired_unit
- indicates the unit to usepublic final double getSimulationStepDuration()
public final SimulationClock getSimulationClock()
getSimulationClock
in interface Environment<AT extends Agent>
null
Copyright © 2003-2013 Arakhnê.org Members. All rights reserved under LGPL license terms.