SUMO - Simulation of Urban MObility
MSPerson::MSPersonStage_Access Class Reference

#include <MSPerson.h>

Inheritance diagram for MSPerson::MSPersonStage_Access:
Inheritance graph
Collaboration diagram for MSPerson::MSPersonStage_Access:
Collaboration graph

Data Structures

class  ProceedCmd
 

Public Member Functions

virtual void abort (MSTransportable *)
 abort this stage (TraCI) More...
 
void beginEventOutput (const MSTransportable &, SUMOTime, OutputDevice &) const
 Called on writing events output (begin of an action). Currently does nothing. More...
 
void endEventOutput (const MSTransportable &, SUMOTime, OutputDevice &) const
 Called on writing events output (end of an action). Currently does nothing. More...
 
double getAngle (SUMOTime now) const
 returns the angle of the transportable More...
 
double getArrivalPos () const
 
const MSEdgegetDestination () const
 returns the destination edge More...
 
MSStoppingPlacegetDestinationStop () const
 returns the destination stop (if any) More...
 
virtual const MSEdgegetEdge () const
 Returns the current edge. More...
 
double getEdgeAngle (const MSEdge *e, double at) const
 get angle of the edge at a certain position More...
 
virtual double getEdgePos (SUMOTime now) const
 
Position getEdgePosition (const MSEdge *e, double at, double offset) const
 get position on edge e at length at with orthogonal offset More...
 
virtual ConstMSEdgeVector getEdges () const
 the edges of the current stage More...
 
virtual const MSEdgegetFromEdge () const
 
Position getLanePosition (const MSLane *lane, double at, double offset) const
 get position on lane at length at with orthogonal offset More...
 
Position getPosition (SUMOTime now) const
 returns the position of the transportable More...
 
virtual double getSpeed () const
 the speed of the transportable More...
 
std::string getStageDescription () const
 returns the stage description as a string More...
 
std::string getStageSummary () const
 return string summary of the current stage More...
 
StageType getStageType () const
 
virtual SUMOVehiclegetVehicle () const
 Whether the transportable waits for a vehicle. More...
 
virtual SUMOTime getWaitingTime (SUMOTime now) const
 the time this transportable spent waiting More...
 
virtual bool isWaiting4Vehicle () const
 Whether the transportable waits for a vehicle. More...
 
virtual bool isWaitingFor (const std::string &line) const
 Whether the transportable waits for a vehicle of the line specified. More...
 
 MSPersonStage_Access (const MSEdge *destination, MSStoppingPlace *toStop, const double arrivalPos, const double dist, const bool isExit)
 constructor More...
 
virtual void proceed (MSNet *net, MSTransportable *person, SUMOTime now, Stage *previous)
 proceeds to the next step More...
 
void routeOutput (OutputDevice &, const bool) const
 Called on writing vehroute output. Currently does nothing. More...
 
virtual void setArrived (MSNet *net, MSTransportable *transportable, SUMOTime now)
 logs end of the step More...
 
void setDeparted (SUMOTime now)
 logs end of the step More...
 
virtual void setSpeed (double)
 sets the walking speed (ignored in other stages) More...
 
void tripInfoOutput (OutputDevice &os, const MSTransportable *const transportable) const
 Called on writing tripinfo output. More...
 
 ~MSPersonStage_Access ()
 destructor More...
 

Protected Attributes

double myArrivalPos
 the position at which we want to arrive More...
 
SUMOTime myArrived
 the time at which this stage ended More...
 
SUMOTime myDeparted
 the time at which this stage started More...
 
const MSEdgemyDestination
 the next edge to reach by getting transported More...
 
MSStoppingPlacemyDestinationStop
 the stop to reach by getting transported (if any) More...
 
StageType myType
 The type of this stage. More...
 

Private Attributes

const bool myAmExit
 
const double myDist
 
SUMOTime myEstimatedArrival
 
PositionVector myPath
 

Detailed Description

An intermediate stage performing the access from or to public transport as given by the access elements of the public transport stop. The travel time is computed by the simulation

Definition at line 274 of file MSPerson.h.

Constructor & Destructor Documentation

◆ MSPersonStage_Access()

MSPerson::MSPersonStage_Access::MSPersonStage_Access ( const MSEdge destination,
MSStoppingPlace toStop,
const double  arrivalPos,
const double  dist,
const bool  isExit 
)

◆ ~MSPersonStage_Access()

MSPerson::MSPersonStage_Access::~MSPersonStage_Access ( )

destructor

Definition at line 488 of file MSPerson.cpp.

Member Function Documentation

◆ abort()

virtual void MSTransportable::Stage::abort ( MSTransportable )
inlinevirtualinherited

abort this stage (TraCI)

Reimplemented in MSTransportable::Stage_Driving, MSTransportable::Stage_Waiting, and MSPerson::MSPersonStage_Walking.

Definition at line 118 of file MSTransportable.h.

◆ beginEventOutput()

void MSPerson::MSPersonStage_Access::beginEventOutput ( const MSTransportable ,
SUMOTime  ,
OutputDevice  
) const
inlinevirtual

Called on writing events output (begin of an action). Currently does nothing.

Implements MSTransportable::Stage.

Definition at line 306 of file MSPerson.h.

◆ endEventOutput()

void MSPerson::MSPersonStage_Access::endEventOutput ( const MSTransportable ,
SUMOTime  ,
OutputDevice  
) const
inlinevirtual

Called on writing events output (end of an action). Currently does nothing.

Implements MSTransportable::Stage.

Definition at line 309 of file MSPerson.h.

◆ getAngle()

double MSPerson::MSPersonStage_Access::getAngle ( SUMOTime  now) const
virtual

returns the angle of the transportable

Implements MSTransportable::Stage.

Definition at line 519 of file MSPerson.cpp.

References PositionVector::angleAt2D(), and myPath.

◆ getArrivalPos()

◆ getDestination()

◆ getDestinationStop()

◆ getEdge()

◆ getEdgeAngle()

double MSTransportable::Stage::getEdgeAngle ( const MSEdge e,
double  at 
) const
inherited

◆ getEdgePos()

◆ getEdgePosition()

Position MSTransportable::Stage::getEdgePosition ( const MSEdge e,
double  at,
double  offset 
) const
inherited

◆ getEdges()

◆ getFromEdge()

const MSEdge * MSTransportable::Stage::getFromEdge ( ) const
virtualinherited

◆ getLanePosition()

Position MSTransportable::Stage::getLanePosition ( const MSLane lane,
double  at,
double  offset 
) const
inherited

◆ getPosition()

Position MSPerson::MSPersonStage_Access::getPosition ( SUMOTime  now) const
virtual

returns the position of the transportable

Implements MSTransportable::Stage.

Definition at line 513 of file MSPerson.cpp.

References PositionVector::length(), MSTransportable::Stage::myDeparted, myEstimatedArrival, myPath, and PositionVector::positionAtOffset().

◆ getSpeed()

double MSTransportable::Stage::getSpeed ( ) const
virtualinherited

◆ getStageDescription()

std::string MSPerson::MSPersonStage_Access::getStageDescription ( ) const
virtual

returns the stage description as a string

Implements MSTransportable::Stage.

Definition at line 501 of file MSPerson.cpp.

◆ getStageSummary()

std::string MSPerson::MSPersonStage_Access::getStageSummary ( ) const
virtual

return string summary of the current stage

Implements MSTransportable::Stage.

Definition at line 507 of file MSPerson.cpp.

References MSTransportable::Stage::getDestinationStop(), Named::getID(), and myAmExit.

◆ getStageType()

◆ getVehicle()

◆ getWaitingTime()

SUMOTime MSTransportable::Stage::getWaitingTime ( SUMOTime  now) const
virtualinherited

◆ isWaiting4Vehicle()

virtual bool MSTransportable::Stage::isWaiting4Vehicle ( ) const
inlinevirtualinherited

Whether the transportable waits for a vehicle.

Reimplemented in MSTransportable::Stage_Driving.

Definition at line 133 of file MSTransportable.h.

◆ isWaitingFor()

bool MSTransportable::Stage::isWaitingFor ( const std::string &  line) const
virtualinherited

Whether the transportable waits for a vehicle of the line specified.

Reimplemented in MSTransportable::Stage_Driving.

Definition at line 113 of file MSTransportable.cpp.

Referenced by MSTransportable::Stage::setSpeed().

◆ proceed()

◆ routeOutput()

void MSPerson::MSPersonStage_Access::routeOutput ( OutputDevice ,
const bool   
) const
inlinevirtual

Called on writing vehroute output. Currently does nothing.

Implements MSTransportable::Stage.

Definition at line 303 of file MSPerson.h.

◆ setArrived()

◆ setDeparted()

void MSTransportable::Stage::setDeparted ( SUMOTime  now)
inherited

logs end of the step

Definition at line 101 of file MSTransportable.cpp.

References MSTransportable::Stage::myDeparted.

Referenced by MSTransportable::getVehicleType(), and MSTransportable::Stage::setSpeed().

◆ setSpeed()

virtual void MSTransportable::Stage::setSpeed ( double  )
inlinevirtualinherited

sets the walking speed (ignored in other stages)

Reimplemented in MSPerson::MSPersonStage_Walking.

Definition at line 121 of file MSTransportable.h.

References MSTransportable::Stage::isWaitingFor(), MSTransportable::Stage::setArrived(), and MSTransportable::Stage::setDeparted().

Referenced by MSTransportable::getVehicle().

◆ tripInfoOutput()

void MSPerson::MSPersonStage_Access::tripInfoOutput ( OutputDevice os,
const MSTransportable *const  transportable 
) const
virtual

Called on writing tripinfo output.

Parameters
[in]osThe stream to write the information into
[in]transportableThe person to write information about
Exceptions
IOErrornot yet implemented

Implements MSTransportable::Stage.

Definition at line 525 of file MSPerson.cpp.

References OutputDevice::closeTag(), MSTransportable::Stage::getDestinationStop(), MSTransportable::getID(), MSTransportable::Stage::myArrived, MSTransportable::Stage::myDeparted, myDist, OutputDevice::openTag(), time2string(), and OutputDevice::writeAttr().

Field Documentation

◆ myAmExit

const bool MSPerson::MSPersonStage_Access::myAmExit
private

Definition at line 327 of file MSPerson.h.

Referenced by getStageSummary().

◆ myArrivalPos

◆ myArrived

◆ myDeparted

◆ myDestination

◆ myDestinationStop

◆ myDist

const double MSPerson::MSPersonStage_Access::myDist
private

Definition at line 326 of file MSPerson.h.

Referenced by proceed(), and tripInfoOutput().

◆ myEstimatedArrival

SUMOTime MSPerson::MSPersonStage_Access::myEstimatedArrival
private

Definition at line 328 of file MSPerson.h.

Referenced by getPosition(), and proceed().

◆ myPath

PositionVector MSPerson::MSPersonStage_Access::myPath
private

Definition at line 329 of file MSPerson.h.

Referenced by getAngle(), getPosition(), and MSPersonStage_Access().

◆ myType

StageType MSTransportable::Stage::myType
protectedinherited

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