SUMO - Simulation of Urban MObility
|
#include <MSPerson.h>
Data Structures | |
class | arrival_finder |
class | MoveToNextEdge |
Public Member Functions | |
virtual void | beginEventOutput (const MSPerson &p, SUMOTime t, OutputDevice &os) const |
Called for writing the events output. More... | |
virtual void | endEventOutput (const MSPerson &p, SUMOTime t, OutputDevice &os) const |
Called for writing the events output (end of an action) More... | |
SUMOReal | getAngle (SUMOTime now) const |
const MSEdge & | getDestination () const |
returns the destination edge More... | |
const MSEdge * | getEdge () const |
Returns the current edge. More... | |
SUMOReal | getEdgeAngle (const MSEdge *e, SUMOReal at) const |
SUMOReal | getEdgePos (SUMOTime now) const |
Position | getEdgePosition (const MSEdge *e, SUMOReal at, SUMOReal offset) const |
get position on edge e at length at with orthogonal offset More... | |
const MSEdge * | getFromEdge () const |
Position | getPosition (SUMOTime now) const |
StageType | getStageType () const |
std::string | getStageTypeName () const |
return string representation of the current stage More... | |
virtual bool | isWaiting4Vehicle () const |
Whether the person waits for a vehicle. More... | |
virtual bool | isWaitingFor (const std::string &line) const |
Whether the person waits for a vehicle of the line specified. More... | |
SUMOTime | moveToNextEdge (MSPerson *person, SUMOTime currentTime) |
MSPersonStage_Walking (const std::vector< const MSEdge * > &route, MSBusStop *toBS, SUMOTime walkingTime, SUMOReal speed, SUMOReal departPos, SUMOReal arrivalPos) | |
constructor More... | |
virtual void | proceed (MSNet *net, MSPerson *person, SUMOTime now, MSEdge *previousEdge, const SUMOReal at) |
proceeds to the next step More... | |
virtual void | routeOutput (OutputDevice &os) const |
Called on writing vehroute output. More... | |
void | setArrived (SUMOTime now) |
logs end of the step More... | |
void | setDeparted (SUMOTime now) |
logs end of the step More... | |
virtual SUMOTime | timeWaiting4Vehicle (SUMOTime) const |
the time this person spent waiting for a vehicle More... | |
virtual void | tripInfoOutput (OutputDevice &os) const |
Called on writing tripinfo output. More... | |
~MSPersonStage_Walking () | |
destructor More... | |
Protected Attributes | |
SUMOTime | myArrived |
the time at which this stage ended More... | |
SUMOTime | myDeparted |
the time at which this stage started More... | |
const MSEdge & | myDestination |
the next edge to reach (either by walking or driving) More... | |
StageType | myType |
The type of this stage. More... | |
Private Member Functions | |
void | computeWalkingTime (const MSEdge *const e, SUMOReal fromPos, SUMOReal toPos, MSBusStop *bs) |
MSPersonStage_Walking (const MSPersonStage_Walking &) | |
Invalidated copy constructor. More... | |
MSPersonStage_Walking & | operator= (const MSPersonStage_Walking &) |
Invalidated assignment operator. More... | |
Private Attributes | |
SUMOReal | myArrivalPos |
SUMOReal | myCurrentBeginPos |
SUMOReal | myCurrentDuration |
SUMOReal | myCurrentLength |
SUMOReal | myDepartPos |
A vector of computed times an edge is reached. More... | |
MSBusStop * | myDestinationBusStop |
SUMOTime | myLastEntryTime |
std::vector< const MSEdge * > | myRoute |
The route of the person. More... | |
std::vector< const MSEdge * > ::iterator | myRouteStep |
SUMOReal | mySpeed |
SUMOTime | myWalkingTime |
the time the person is walking More... | |
A "real" stage performing the walking to an edge The walking does not need any route as it is not simulated. Only the duration is needed
Definition at line 186 of file MSPerson.h.
MSPerson::MSPersonStage_Walking::MSPersonStage_Walking | ( | const std::vector< const MSEdge * > & | route, |
MSBusStop * | toBS, | ||
SUMOTime | walkingTime, | ||
SUMOReal | speed, | ||
SUMOReal | departPos, | ||
SUMOReal | arrivalPos | ||
) |
constructor
Definition at line 117 of file MSPerson.cpp.
References SUMOVehicleParameter::interpretEdgePos(), myArrivalPos, myDepartPos, myRoute, mySpeed, STEPS2TIME, SUMO_ATTR_ARRIVALPOS, SUMO_ATTR_DEPARTPOS, and SUMOReal.
MSPerson::MSPersonStage_Walking::~MSPersonStage_Walking | ( | ) |
destructor
Definition at line 140 of file MSPerson.cpp.
|
private |
Invalidated copy constructor.
|
virtual |
Called for writing the events output.
[in] | os | The stream to write the information into |
IOError | not yet implemented |
Implements MSPerson::MSPersonStage.
Definition at line 238 of file MSPerson.cpp.
References MSPerson::getID(), OutputDevice::openTag(), time2string(), and OutputDevice::writeAttr().
|
private |
Definition at line 203 of file MSPerson.cpp.
References MSBusStop::getEndLanePosition(), MSEdge::getLanes(), MAX2(), and SUMOReal.
|
virtual |
Called for writing the events output (end of an action)
[in] | os | The stream to write the information into |
IOError | not yet implemented |
Implements MSPerson::MSPersonStage.
Definition at line 245 of file MSPerson.cpp.
References MSPerson::getID(), OutputDevice::openTag(), time2string(), and OutputDevice::writeAttr().
Implements MSPerson::MSPersonStage.
Definition at line 171 of file MSPerson.cpp.
References MSPerson::getEdge(), STEPS2TIME, and SUMOReal.
|
inherited |
returns the destination edge
Definition at line 70 of file MSPerson.cpp.
|
virtual |
Returns the current edge.
Implements MSPerson::MSPersonStage.
Definition at line 144 of file MSPerson.cpp.
Definition at line 106 of file MSPerson.cpp.
References MSEdge::getLanes(), and PositionVector::rotationDegreeAtOffset().
Implements MSPerson::MSPersonStage.
Definition at line 156 of file MSPerson.cpp.
References STEPS2TIME, and SUMOReal.
|
inherited |
get position on edge e at length at with orthogonal offset
Definition at line 96 of file MSPerson.cpp.
References MSEdge::getLanes(), MSLane::getShape(), MSLane::interpolateLanePosToGeometryPos(), PositionVector::move2side(), and PositionVector::positionAtOffset().
|
virtual |
Implements MSPerson::MSPersonStage.
Definition at line 150 of file MSPerson.cpp.
Implements MSPerson::MSPersonStage.
Definition at line 163 of file MSPerson.cpp.
References MSPerson::getEdge(), MSPerson::SIDEWALK_OFFSET, STEPS2TIME, and SUMOReal.
|
inlineinherited |
Definition at line 100 of file MSPerson.h.
References MSPerson::MSPersonStage::myType.
|
inlinevirtual |
return string representation of the current stage
Implements MSPerson::MSPersonStage.
Definition at line 207 of file MSPerson.h.
|
inlinevirtualinherited |
Whether the person waits for a vehicle.
Reimplemented in MSPerson::MSPersonStage_Driving.
Definition at line 120 of file MSPerson.h.
|
virtualinherited |
Whether the person waits for a vehicle of the line specified.
Reimplemented in MSPerson::MSPersonStage_Driving.
Definition at line 90 of file MSPerson.cpp.
SUMOTime MSPerson::MSPersonStage_Walking::moveToNextEdge | ( | MSPerson * | person, |
SUMOTime | currentTime | ||
) |
Definition at line 252 of file MSPerson.cpp.
References MSPersonControl::erase(), MSNet::getInstance(), MSNet::getPersonControl(), MSPerson::proceed(), TIME2STEPS, and MSPersonControl::unsetWalking().
Referenced by MSPerson::MSPersonStage_Walking::MoveToNextEdge::execute().
|
private |
Invalidated assignment operator.
|
virtual |
proceeds to the next step
Implements MSPerson::MSPersonStage.
Definition at line 179 of file MSPerson.cpp.
References MSEventControl::ADAPT_AFTER_EXECUTION, MSEventControl::addEvent(), MSPersonControl::erase(), MSNet::getBeginOfTimestepEvents(), MSNet::getInstance(), MSNet::getPersonControl(), MSPerson::proceed(), MSEdge::removePerson(), MSPersonControl::setWalking(), and TIME2STEPS.
|
virtual |
Called on writing vehroute output.
[in] | os | The stream to write the information into |
IOError | not yet implemented |
Implements MSPerson::MSPersonStage.
Definition at line 226 of file MSPerson.cpp.
References OutputDevice::closeTag(), OutputDevice::openTag(), SUMO_ATTR_DURATION, SUMO_ATTR_EDGES, SUMO_ATTR_SPEED, time2string(), and OutputDevice::writeAttr().
|
inherited |
logs end of the step
Definition at line 84 of file MSPerson.cpp.
|
inherited |
logs end of the step
Definition at line 76 of file MSPerson.cpp.
|
inlinevirtualinherited |
the time this person spent waiting for a vehicle
Reimplemented in MSPerson::MSPersonStage_Driving.
Definition at line 125 of file MSPerson.h.
|
virtual |
Called on writing tripinfo output.
[in] | os | The stream to write the information into |
IOError | not yet implemented |
Implements MSPerson::MSPersonStage.
Definition at line 220 of file MSPerson.cpp.
References OutputDevice::closeTag(), OutputDevice::openTag(), time2string(), and OutputDevice::writeAttr().
|
private |
Definition at line 273 of file MSPerson.h.
Referenced by MSPersonStage_Walking().
|
protectedinherited |
the time at which this stage ended
Definition at line 167 of file MSPerson.h.
|
private |
Definition at line 278 of file MSPerson.h.
|
private |
Definition at line 278 of file MSPerson.h.
|
private |
Definition at line 278 of file MSPerson.h.
|
protectedinherited |
the time at which this stage started
Definition at line 164 of file MSPerson.h.
|
private |
A vector of computed times an edge is reached.
Definition at line 272 of file MSPerson.h.
Referenced by MSPersonStage_Walking().
|
protectedinherited |
the next edge to reach (either by walking or driving)
Definition at line 161 of file MSPerson.h.
Referenced by MSPerson::MSPersonStage_Waiting::MSPersonStage_Waiting().
|
private |
Definition at line 274 of file MSPerson.h.
|
private |
Definition at line 275 of file MSPerson.h.
|
private |
The route of the person.
Definition at line 264 of file MSPerson.h.
Referenced by MSPersonStage_Walking().
|
private |
Definition at line 267 of file MSPerson.h.
|
private |
Definition at line 276 of file MSPerson.h.
Referenced by MSPersonStage_Walking().
|
protectedinherited |
The type of this stage.
Definition at line 170 of file MSPerson.h.
Referenced by MSPerson::MSPersonStage::getStageType().
|
private |
the time the person is walking
Definition at line 261 of file MSPerson.h.