public class VacuumEnvironmentViewActionTracker extends java.lang.Object implements EnvironmentView
Constructor and Description |
---|
VacuumEnvironmentViewActionTracker(java.lang.StringBuilder envChanges) |
Modifier and Type | Method and Description |
---|---|
void |
agentActed(Agent agent,
Action action,
Environment source)
Indicates the Environment has changed as a result of an Agent's action.
|
void |
agentAdded(Agent agent,
Environment source)
Indicates an Agent has been added to the environment and what it
perceives initially.
|
void |
notify(java.lang.String msg)
A simple notification message from an object in the Environment.
|
public VacuumEnvironmentViewActionTracker(java.lang.StringBuilder envChanges)
public void notify(java.lang.String msg)
EnvironmentView
notify
in interface EnvironmentView
msg
- the message received.public void agentAdded(Agent agent, Environment source)
EnvironmentView
agentAdded
in interface EnvironmentView
agent
- the Agent just added to the Environment.source
- the Environment to which the agent was added.public void agentActed(Agent agent, Action action, Environment source)
EnvironmentView
agentActed
in interface EnvironmentView
agent
- the Agent that performed the Action.action
- the Action the Agent performed.source
- the Environment in which the agent has acted.