public class VacuumWorld extends Environment
Constructor and Description |
---|
VacuumWorld() |
VacuumWorld(boolean interactive) |
VacuumWorld(java.io.PrintStream output,
boolean interactive) |
Modifier and Type | Method and Description |
---|---|
void |
addAgent(Agent agent)
Add a new agent to the environment.
|
int |
getPerformanceMeasure(Agent ag)
Returns the performance measure of the agent in the current
environment.
|
int |
getTeamPerformanceMeasure()
Returns the performance measure of an agent team in the current
environment.
|
static void |
main(java.lang.String[] args)
Runs the program.
|
void |
start(State initState)
Starts the simulation.
|
public VacuumWorld()
public VacuumWorld(boolean interactive)
public VacuumWorld(java.io.PrintStream output, boolean interactive)
public void addAgent(Agent agent)
addAgent
in class Environment
public void start(State initState)
start
in class Environment
public static void main(java.lang.String[] args)
java vacworld.VacuumWorld [-batch] [-rand integer] agentpackThe package containing the agent code (the VacAgent class) must be specified as a command-line parameter. By default, it runs in interactive mode, requiring the user to press a key after each action. To run in batch mode, use the -batch switch. To test the agent in different configurations, use the -rand seed argument, where seed is an integer to be used by the pseudo-random number generator.
public int getTeamPerformanceMeasure()
getTeamPerformanceMeasure
in class Environment
public int getPerformanceMeasure(Agent ag)
getPerformanceMeasure
in class Environment