SUMO - Simulation of Urban MObility
MSPModel_NonInteracting::PState Class Reference

abstract base class for managing callbacks to retrieve various state information from the model More...

Inheritance diagram for MSPModel_NonInteracting::PState:
Inheritance graph
Collaboration diagram for MSPModel_NonInteracting::PState:
Collaboration graph

Public Member Functions

SUMOTime computeWalkingTime (const MSEdge *prev, const MSPerson::MSPersonStage_Walking &stage, SUMOTime currentTime)
 compute walking time on edge and update state members More...
 
MoveToNextEdgegetCommand ()
 
 PState (MoveToNextEdge *cmd)
 
double getEdgePos (const MSPerson::MSPersonStage_Walking &stage, SUMOTime now) const
 abstract methods inherited from PedestrianState More...
 
Position getPosition (const MSPerson::MSPersonStage_Walking &stage, SUMOTime now) const
 return the network coordinate of the person More...
 
double getAngle (const MSPerson::MSPersonStage_Walking &stage, SUMOTime now) const
 return the direction in which the person faces in degrees More...
 
SUMOTime getWaitingTime (const MSPerson::MSPersonStage_Walking &stage, SUMOTime now) const
 return the time the person spent standing More...
 
double getSpeed (const MSPerson::MSPersonStage_Walking &stage) const
 return the current speed of the person More...
 
const MSEdgegetNextEdge (const MSPerson::MSPersonStage_Walking &stage) const
 return the list of internal edges if the pedestrian is on an intersection More...
 

Private Attributes

MoveToNextEdgemyCommand
 
double myCurrentBeginPos
 
SUMOTime myCurrentDuration
 
double myCurrentEndPos
 
SUMOTime myLastEntryTime
 

Detailed Description

abstract base class for managing callbacks to retrieve various state information from the model

Definition at line 92 of file MSPModel_NonInteracting.h.

Constructor & Destructor Documentation

◆ PState()

MSPModel_NonInteracting::PState::PState ( MoveToNextEdge cmd)
inline

Definition at line 94 of file MSPModel_NonInteracting.h.

Member Function Documentation

◆ computeWalkingTime()

◆ getAngle()

double MSPModel_NonInteracting::PState::getAngle ( const MSPerson::MSPersonStage_Walking stage,
SUMOTime  now 
) const
virtual

return the direction in which the person faces in degrees

Implements PedestrianState.

Definition at line 164 of file MSPModel_NonInteracting.cpp.

References MSPerson::MSPersonStage_Walking::getEdge(), MSTransportable::Stage::getEdgeAngle(), and M_PI.

◆ getCommand()

MoveToNextEdge* MSPModel_NonInteracting::PState::getCommand ( )
inline

Definition at line 108 of file MSPModel_NonInteracting.h.

◆ getEdgePos()

double MSPModel_NonInteracting::PState::getEdgePos ( const MSPerson::MSPersonStage_Walking stage,
SUMOTime  now 
) const
virtual

abstract methods inherited from PedestrianState

Implements PedestrianState.

Definition at line 149 of file MSPModel_NonInteracting.cpp.

◆ getNextEdge()

const MSEdge * MSPModel_NonInteracting::PState::getNextEdge ( const MSPerson::MSPersonStage_Walking stage) const
virtual

return the list of internal edges if the pedestrian is on an intersection

Implements PedestrianState.

Definition at line 187 of file MSPModel_NonInteracting.cpp.

References MSPerson::MSPersonStage_Walking::getNextRouteEdge().

◆ getPosition()

Position MSPModel_NonInteracting::PState::getPosition ( const MSPerson::MSPersonStage_Walking stage,
SUMOTime  now 
) const
virtual

◆ getSpeed()

double MSPModel_NonInteracting::PState::getSpeed ( const MSPerson::MSPersonStage_Walking stage) const
virtual

return the current speed of the person

Implements PedestrianState.

Definition at line 181 of file MSPModel_NonInteracting.cpp.

References MSPerson::MSPersonStage_Walking::getMaxSpeed().

◆ getWaitingTime()

SUMOTime MSPModel_NonInteracting::PState::getWaitingTime ( const MSPerson::MSPersonStage_Walking stage,
SUMOTime  now 
) const
virtual

return the time the person spent standing

Implements PedestrianState.

Definition at line 175 of file MSPModel_NonInteracting.cpp.

Field Documentation

◆ myCommand

MoveToNextEdge* MSPModel_NonInteracting::PState::myCommand
private

Definition at line 117 of file MSPModel_NonInteracting.h.

◆ myCurrentBeginPos

double MSPModel_NonInteracting::PState::myCurrentBeginPos
private

Definition at line 115 of file MSPModel_NonInteracting.h.

◆ myCurrentDuration

SUMOTime MSPModel_NonInteracting::PState::myCurrentDuration
private

Definition at line 114 of file MSPModel_NonInteracting.h.

◆ myCurrentEndPos

double MSPModel_NonInteracting::PState::myCurrentEndPos
private

Definition at line 116 of file MSPModel_NonInteracting.h.

◆ myLastEntryTime

SUMOTime MSPModel_NonInteracting::PState::myLastEntryTime
private

Definition at line 113 of file MSPModel_NonInteracting.h.


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