Menge
Modular Pedestrian Simulation Framework for Research and Development
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Protected Attributes | List of all members
Menge::Agents::SimulatorState Class Reference

A class which caches the state of the simulator. More...

#include <SimulatorState.h>

Public Member Functions

 SimulatorState ()
 Constructor.
 
void setAgentState (size_t id, const std::string &stateName)
 Sets the state for the given agent. More...
 
const std::string getAgentState (size_t id) const
 Reports the state name for the given agent. More...
 

Protected Attributes

HASH_MAP< size_t, std::string > _agentStates
 A mapping from agent id to state name.
 

Detailed Description

A class which caches the state of the simulator.

This version of the class is, as yet, incomplete. Ultimately, it will store all critical parameters of the simulator such that the simulation can be restarted from this state.

This version is currently used to determine agent's starting state.

Member Function Documentation

const std::string Menge::Agents::SimulatorState::getAgentState ( size_t  id) const

Reports the state name for the given agent.

Parameters
idThe identifier of the agent.
Returns
The name of this agent's start state.
void Menge::Agents::SimulatorState::setAgentState ( size_t  id,
const std::string &  stateName 
)

Sets the state for the given agent.

Parameters
idThe identifier of the agent.
stateNameThe name of the state to which the agent belongs.

The documentation for this class was generated from the following files: