Eclipse SUMO - Simulation of Urban MObility
All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
MSStop Class Reference

#include <MSStop.h>

Collaboration diagram for MSStop:
[legend]

Public Member Functions

SUMOTime getArrival () const
 return arrival / started time
 
std::string getDescription () const
 get a short description for showing in the gui
 
const MSEdgegetEdge () const
 
double getEndPos (const SUMOVehicle &veh) const
 return halting position for upcoming stop;
 
SUMOTime getMinDuration (SUMOTime time) const
 return minimum stop duration when starting stop at time
 
std::vector< MSStoppingPlace * > getPlaces () const
 return all stoppingPlaces associated with this stop
 
double getReachedThreshold () const
 return startPos taking into account opposite stopping
 
double getSpeed () const
 return speed for passing waypoint / skipping on-demand stop
 
int getStateFlagsOld () const
 return flags as used by Vehicle::getStopState
 
SUMOTime getUntil () const
 return until / ended time
 
void initPars (const SUMOVehicleParameter::Stop &stopPar)
 initialize attributes from the given stop parameters
 
bool isInRange (const double pos, const double tolerance) const
 whether the stop is in range of the given position
 
 MSStop (const SUMOVehicleParameter::Stop &par)
 
void write (OutputDevice &dev) const
 Write the current stop configuration (used for state saving)
 

Data Fields

MSStoppingPlacebusstop = nullptr
 (Optional) bus stop if one is assigned to the stop
 
MSStoppingPlacechargingStation = nullptr
 (Optional) charging station if one is assigned to the stop
 
MSStoppingPlacecontainerstop = nullptr
 (Optional) container stop if one is assigned to the stop
 
bool containerTriggered = false
 whether an arriving container lets the vehicle continue
 
SUMOTime duration = -1
 The stopping duration.
 
MSRouteIterator edge
 The edge in the route to stop at.
 
SUMOTime endBoarding = SUMOTime_MAX
 the maximum time at which persons may board this vehicle
 
bool isOpposite = false
 whether this an opposite-direction stop
 
bool joinTriggered = false
 whether coupling another vehicle (train) the vehicle continue
 
const MSLanelane = nullptr
 The lane to stop at (microsim only)
 
int numExpectedContainer = 0
 The number of still expected containers.
 
int numExpectedPerson = 0
 The number of still expected persons.
 
MSStoppingPlaceoverheadWireSegment = nullptr
 (Optional) overhead wire segment if one is assigned to the stop
 
MSParkingAreaparkingarea = nullptr
 (Optional) parkingArea if one is assigned to the stop
 
const SUMOVehicleParameter::Stop pars
 The stop parameter.
 
bool reached = false
 Information whether the stop has been reached.
 
const MESegmentsegment = nullptr
 The segment to stop at (mesosim only)
 
bool skipOnDemand = false
 whether the decision to skip this stop has been made
 
bool startedFromState = false
 whether the 'started' value was loaded from simulaton state
 
SUMOTime timeToBoardNextPerson = 0
 The time at which the vehicle is able to board another person.
 
SUMOTime timeToLoadNextContainer = 0
 The time at which the vehicle is able to load another container.
 
bool triggered = false
 whether an arriving person lets the vehicle continue
 

Detailed Description

Definition at line 44 of file MSStop.h.

Constructor & Destructor Documentation

◆ MSStop()

MSStop::MSStop ( const SUMOVehicleParameter::Stop par)
inline

Definition at line 46 of file MSStop.h.

Member Function Documentation

◆ getArrival()

SUMOTime MSStop::getArrival ( ) const

return arrival / started time

Definition at line 157 of file MSStop.cpp.

References SUMOVehicleParameter::Stop::arrival, MSGlobals::gUseStopStarted, pars, and SUMOVehicleParameter::Stop::started.

Referenced by MSBaseVehicle::addStop().

Here is the caller graph for this function:

◆ getDescription()

std::string MSStop::getDescription ( ) const

get a short description for showing in the gui

Definition at line 69 of file MSStop.cpp.

References SUMOVehicleParameter::Stop::actType, busstop, chargingStation, containerstop, SUMOVehicleParameter::Stop::endPos, Named::getID(), lane, overheadWireSegment, parkingarea, pars, and toString().

Referenced by MSBaseVehicle::addStop().

Here is the caller graph for this function:

◆ getEdge()

const MSEdge * MSStop::getEdge ( ) const

Definition at line 54 of file MSStop.cpp.

References MESegment::getEdge(), MSLane::getEdge(), lane, and segment.

Referenced by MSStageDriving::canLeaveVehicle(), getEndPos(), and MSVehicle::processNextStop().

Here is the caller graph for this function:

◆ getEndPos()

◆ getMinDuration()

SUMOTime MSStop::getMinDuration ( SUMOTime  time) const

return minimum stop duration when starting stop at time

Definition at line 134 of file MSStop.cpp.

References duration, SUMOVehicleParameter::Stop::ended, MSGlobals::gUseStopEnded, MAX2(), pars, and SUMOVehicleParameter::Stop::until.

Referenced by MSTriggeredRerouter::checkStopSwitch(), MSDevice_StationFinder::planOpportunisticCharging(), and MSVehicle::processNextStop().

Here is the caller graph for this function:

◆ getPlaces()

std::vector< MSStoppingPlace * > MSStop::getPlaces ( ) const

return all stoppingPlaces associated with this stop

Definition at line 175 of file MSStop.cpp.

References busstop, chargingStation, containerstop, overheadWireSegment, and parkingarea.

Referenced by MSTriggeredRerouter::checkStopSwitch().

Here is the caller graph for this function:

◆ getReachedThreshold()

double MSStop::getReachedThreshold ( ) const

return startPos taking into account opposite stopping

Definition at line 64 of file MSStop.cpp.

References SUMOVehicleParameter::Stop::endPos, MSLane::getOppositePos(), isOpposite, lane, pars, and SUMOVehicleParameter::Stop::startPos.

Referenced by MSVehicle::processNextStop().

Here is the caller graph for this function:

◆ getSpeed()

double MSStop::getSpeed ( ) const

return speed for passing waypoint / skipping on-demand stop

Definition at line 163 of file MSStop.cpp.

References pars, skipOnDemand, and SUMOVehicleParameter::Stop::speed.

Referenced by MSVehicle::estimateTimeToNextStop(), MSVehicle::planMoveInternal(), MSVehicle::processNextStop(), MSVehicle::resumeFromStopping(), and MSVehicle::updateBestLanes().

Here is the caller graph for this function:

◆ getStateFlagsOld()

int MSStop::getStateFlagsOld ( ) const

return flags as used by Vehicle::getStopState

Definition at line 128 of file MSStop.cpp.

References SUMOVehicleParameter::Stop::getFlags(), pars, and reached.

Referenced by LIBSUMO_NAMESPACE::Vehicle::getStopState().

Here is the caller graph for this function:

◆ getUntil()

SUMOTime MSStop::getUntil ( ) const

return until / ended time

Definition at line 151 of file MSStop.cpp.

References SUMOVehicleParameter::Stop::ended, MSGlobals::gUseStopEnded, pars, and SUMOVehicleParameter::Stop::until.

Referenced by MSBaseVehicle::addStop(), MSVehicle::planMoveInternal(), MSDevice_StationFinder::planOpportunisticCharging(), and MSVehicle::processNextStop().

Here is the caller graph for this function:

◆ initPars()

◆ isInRange()

bool MSStop::isInRange ( const double  pos,
const double  tolerance 
) const

whether the stop is in range of the given position

Definition at line 169 of file MSStop.cpp.

References SUMOVehicleParameter::Stop::endPos, pars, and SUMOVehicleParameter::Stop::startPos.

Referenced by MSStageDriving::canLeaveVehicle().

Here is the caller graph for this function:

◆ write()

Field Documentation

◆ busstop

MSStoppingPlace* MSStop::busstop = nullptr

(Optional) bus stop if one is assigned to the stop

Definition at line 54 of file MSStop.h.

Referenced by MSBaseVehicle::addStop(), getDescription(), getEndPos(), getPlaces(), initPars(), MSVehicle::leaveLane(), MSVehicle::processNextStop(), MSVehicle::resumeFromStopping(), and write().

◆ chargingStation

◆ containerstop

MSStoppingPlace* MSStop::containerstop = nullptr

(Optional) container stop if one is assigned to the stop

Definition at line 56 of file MSStop.h.

Referenced by MSBaseVehicle::addStop(), getDescription(), getEndPos(), getPlaces(), initPars(), MSVehicle::leaveLane(), MSVehicle::processNextStop(), MSVehicle::resumeFromStopping(), and write().

◆ containerTriggered

bool MSStop::containerTriggered = false

◆ duration

◆ edge

◆ endBoarding

SUMOTime MSStop::endBoarding = SUMOTime_MAX

the maximum time at which persons may board this vehicle

Definition at line 85 of file MSStop.h.

Referenced by MSVehicle::boardTransportables(), MSVehicle::processNextStop(), and MSDevice_Taxi::updateMove().

◆ isOpposite

bool MSStop::isOpposite = false

◆ joinTriggered

bool MSStop::joinTriggered = false

whether coupling another vehicle (train) the vehicle continue

Definition at line 73 of file MSStop.h.

Referenced by MSVehicleControl::abortWaiting(), MSTriggeredRerouter::checkStopSwitch(), MSDevice_Taxi::dispatchShared(), initPars(), MSVehicle::processNextStop(), and MEVehicle::resumeFromStopping().

◆ lane

◆ numExpectedContainer

int MSStop::numExpectedContainer = 0

The number of still expected containers.

Definition at line 79 of file MSStop.h.

Referenced by MSVehicle::boardTransportables(), and initPars().

◆ numExpectedPerson

int MSStop::numExpectedPerson = 0

The number of still expected persons.

Definition at line 77 of file MSStop.h.

Referenced by MSVehicle::boardTransportables(), and initPars().

◆ overheadWireSegment

MSStoppingPlace* MSStop::overheadWireSegment = nullptr

(Optional) overhead wire segment if one is assigned to the stop

Todo:
Check that this should really be a stopping place instance

Definition at line 63 of file MSStop.h.

Referenced by MSBaseVehicle::addStop(), getDescription(), getEndPos(), getPlaces(), and initPars().

◆ parkingarea

◆ pars

◆ reached

◆ segment

const MESegment* MSStop::segment = nullptr

The segment to stop at (mesosim only)

Definition at line 52 of file MSStop.h.

Referenced by MSBaseVehicle::addStop(), getEdge(), MSBaseVehicle::insertStop(), MEVehicle::processStop(), and MSBaseVehicle::replaceStop().

◆ skipOnDemand

bool MSStop::skipOnDemand = false

whether the decision to skip this stop has been made

Definition at line 89 of file MSStop.h.

Referenced by MSVehicle::boardTransportables(), getSpeed(), and MSVehicle::processNextStop().

◆ startedFromState

bool MSStop::startedFromState = false

whether the 'started' value was loaded from simulaton state

Definition at line 91 of file MSStop.h.

Referenced by MSVehicle::processNextStop().

◆ timeToBoardNextPerson

SUMOTime MSStop::timeToBoardNextPerson = 0

The time at which the vehicle is able to board another person.

Definition at line 81 of file MSStop.h.

Referenced by MSVehicle::boardTransportables(), and MSDevice_Transportable::notifyMove().

◆ timeToLoadNextContainer

SUMOTime MSStop::timeToLoadNextContainer = 0

The time at which the vehicle is able to load another container.

Definition at line 83 of file MSStop.h.

Referenced by MSVehicle::boardTransportables(), and MSDevice_Transportable::notifyMove().

◆ triggered

bool MSStop::triggered = false

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