23 #ifndef MSPersonControl_h
24 #define MSPersonControl_h
virtual MSPerson * buildPerson(const SUMOVehicleParameter *pars, const MSVehicleType *vtype, MSPerson::MSPersonPlan *plan) const
Builds a new person.
Representation of a vehicle in the micro simulation.
bool boardAnyWaiting(MSEdge *edge, MSVehicle *vehicle)
board any applicable persons Boards any people who wait on that edge for the given vehicle and remove...
std::map< std::string, MSPerson * > myWalking
all persons by id
std::map< SUMOTime, PersonVector > myWaiting4Departure
Persons waiting for departure.
MSPersonControl()
constructor
The simulated network and simulation perfomer.
The car-following model and parameter.
bool hasPersons() const
checks whether any person waits to finish her plan
std::map< std::string, MSPerson * > myPersons
all persons by id
A road/street connecting two junctions.
bool add(const std::string &id, MSPerson *person)
adds a single person, returns false if an id clash occured
void abortWaiting()
aborts the plan for any person that is still waiting for a ride
void addWaiting(const MSEdge *edge, MSPerson *person)
adds a person to the list of persons waiting for a vehicle on the specified edge
void checkWaitingPersons(MSNet *net, const SUMOTime time)
checks whether any persons waiting or walking time is over
void setWaitEnd(SUMOTime time, MSPerson *person)
sets the arrival time for a waiting or walking person
void unsetWalking(MSPerson *p)
std::map< const MSEdge *, PersonVector > myWaiting4Vehicle
the lists of waiting persons
bool hasNonWaiting() const
checks whether any person is still engaged in walking / stopping
Structure representing possible vehicle parameter.
void setWalking(MSPerson *p)
std::map< SUMOTime, PersonVector > myWaitingUntil
the lists of walking / stopping persons
void setDeparture(SUMOTime time, MSPerson *person)
sets the arrival time for a waiting or walking person
const std::map< std::string, MSPerson * > & getPersons() const
std::vector< MSPerson * > PersonVector
virtual void erase(MSPerson *person)
removes a single person
std::vector< MSPersonStage * > MSPersonPlan
the structure holding the plan of a person
virtual ~MSPersonControl()
destructor
bool isWaiting4Vehicle(const MSEdge *const edge, MSPerson *p) const
returns whether the the given person is waiting for a vehicle on the given edge