Eclipse SUMO - Simulation of Urban MObility
SUMOVehicle Class Referenceabstract

Representation of a vehicle. More...

#include <SUMOVehicle.h>

Inheritance diagram for SUMOVehicle:
Collaboration diagram for SUMOVehicle:

Public Types

typedef long long int NumericalID
 

Public Member Functions

virtual void addContainer (MSTransportable *container)=0
 Adds a container to this vehicle. More...
 
virtual void addPerson (MSTransportable *person)=0
 Adds a person to this vehicle. More...
 
virtual bool addStop (const SUMOVehicleParameter::Stop &stopPar, std::string &errorMsg, SUMOTime untilOffset=0, bool collision=false, ConstMSEdgeVector::const_iterator *searchStart=0)=0
 Adds a stop. More...
 
virtual double getAcceleration () const =0
 Returns the vehicle's acceleration. More...
 
virtual SUMOTime getAccumulatedWaitingTime () const =0
 
virtual double getAngle () const =0
 Get the vehicle's angle. More...
 
virtual double getArrivalPos () const =0
 Returns this vehicle's desired arrivalPos for its current route (may change on reroute) More...
 
virtual double getBackPositionOnLane (const MSLane *lane) const =0
 Get the vehicle's back position along the given lane. More...
 
virtual double getBrakeGap () const =0
 get distance for coming to a stop (used for rerouting checks) More...
 
virtual double getChosenSpeedFactor () const =0
 
virtual int getContainerNumber () const =0
 Returns the number of containers. More...
 
virtual const std::vector< MSTransportable * > & getContainers () const =0
 retrieve riding containers More...
 
virtual const ConstMSEdgeVector::const_iterator & getCurrentRouteEdge () const =0
 Returns an iterator pointing to the current edge in this vehicles route. More...
 
virtual SUMOTime getDepartDelay () const =0
 
virtual double getDepartPos () const =0
 Returns this vehicle's real departure position. More...
 
virtual SUMOTime getDeparture () const =0
 Returns this vehicle's real departure time. More...
 
virtual MSVehicleDevicegetDevice (const std::type_info &type) const =0
 Returns a device of the given type if it exists or 0. More...
 
virtual const std::vector< MSVehicleDevice * > & getDevices () const =0
 Returns this vehicle's devices. More...
 
virtual const MSEdgegetEdge () const =0
 Returns the edge the vehicle is currently at. More...
 
virtual const std::map< int, double > * getEmissionParameters () const =0
 Returns the vehicle's emission model parameter. More...
 
virtual const std::string & getID () const =0
 Get the vehicle's ID. More...
 
virtual double getImpatience () const =0
 Returns this vehicles impatience. More...
 
virtual MSLanegetLane () const =0
 Returns the lane the vehicle is on. More...
 
virtual double getLateralPositionOnLane () const =0
 Get the vehicle's lateral position on the lane. More...
 
virtual double getMaxSpeed () const =0
 Returns the vehicle's maximum speed. More...
 
virtual MSParkingAreagetNextParkingArea ()=0
 
virtual int getNumberReroutes () const =0
 Returns the number of new routes this vehicle got. More...
 
virtual NumericalID getNumericalID () const =0
 return the numerical ID which is only for internal usage More...
 
virtual const SUMOVehicleParametergetParameter () const =0
 Returns the vehicle's parameter (including departure definition) More...
 
virtual std::vector< std::string > getPersonIDList () const =0
 Returns the list of persons. More...
 
virtual int getPersonNumber () const =0
 Returns the number of persons. More...
 
virtual const std::vector< MSTransportable * > & getPersons () const =0
 retrieve riding persons More...
 
virtual Position getPosition (const double offset=0) const =0
 Return current position (x/y, cartesian) More...
 
virtual double getPositionOnLane () const =0
 Get the vehicle's position along the lane. More...
 
virtual double getPreviousSpeed () const =0
 Returns the vehicle's previous speed. More...
 
virtual std::mt19937 * getRNG () const =0
 Returns the associated RNG for this vehicle. More...
 
virtual int getRNGIndex () const =0
 
virtual const MSRoutegetRoute () const =0
 Returns the current route. More...
 
virtual double getSlope () const =0
 Returns the slope of the road at vehicle's position. More...
 
virtual double getSpeed () const =0
 Returns the vehicle's current speed. More...
 
virtual std::vector< std::pair< int, double > > getStopIndices () const =0
 return list of route indices and stop positions for the remaining stops More...
 
virtual SUMOVehicleClass getVClass () const =0
 Returns the vehicle's access class. More...
 
virtual const MSVehicleTypegetVehicleType () const =0
 Returns the vehicle's type. More...
 
virtual SUMOTime getWaitingTime () const =0
 
virtual bool hasArrived () const =0
 Returns whether this vehicle has arrived. More...
 
virtual bool hasDeparted () const =0
 Returns whether this vehicle has departed. More...
 
virtual bool hasValidRoute (std::string &msg, const MSRoute *route=0) const =0
 Validates the current or given route. More...
 
virtual bool isFrontOnLane (const MSLane *) const =0
 Returns the information whether the front of the vehhicle is on the given lane. More...
 
virtual bool isOnRoad () const =0
 Returns the information whether the vehicle is on a road (is simulated) More...
 
virtual bool isParking () const =0
 Returns the information whether the vehicle is parked. More...
 
virtual bool isRemoteControlled () const =0
 Returns the information whether the vehicle is fully controlled via TraCI. More...
 
virtual bool isSelected () const =0
 whether this vehicle is selected in the GUI More...
 
virtual bool isStopped () const =0
 Returns whether the vehicle is at a stop. More...
 
virtual bool isStoppedInRange (const double pos, const double tolerance) const =0
 Returns whether the vehicle is stopped in the range of the given position. More...
 
virtual bool isStoppedTriggered () const =0
 Returns whether the vehicle is at a stop and waiting for a person or container to continue. More...
 
virtual bool isVehicle () const =0
 Get the vehicle's ID. More...
 
virtual void onDepart ()=0
 Called when the vehicle is inserted into the network. More...
 
virtual SUMOTime remainingStopDuration () const =0
 Returns the remaining stop duration for a stopped vehicle or 0. More...
 
virtual void removeTransportable (MSTransportable *t)=0
 removes a person or container More...
 
virtual void replaceParameter (const SUMOVehicleParameter *newParameter)=0
 Replaces the vehicle's parameter. More...
 
virtual bool replaceParkingArea (MSParkingArea *parkingArea, std::string &errorMsg)=0
 Replaces a stop. More...
 
virtual bool replaceRoute (const MSRoute *route, const std::string &info, bool onInit=false, int offset=0, bool addStops=true, bool removeStops=true)=0
 Replaces the current route by the given one. More...
 
virtual bool replaceRouteEdges (ConstMSEdgeVector &edges, double cost, double savings, const std::string &info, bool onInit=false, bool check=false, bool removeStops=true)=0
 Replaces the current route by the given edges. More...
 
virtual void reroute (SUMOTime t, const std::string &info, SUMOAbstractRouter< MSEdge, SUMOVehicle > &router, const bool onInit=false, const bool withTaz=false, const bool silent=false)=0
 Performs a rerouting using the given router. More...
 
virtual void setArrivalPos (double arrivalPos)=0
 Sets this vehicle's desired arrivalPos for its current route. More...
 
virtual void setChosenSpeedFactor (const double factor)=0
 
virtual bool stopsAt (MSStoppingPlace *stop) const =0
 Returns whether the vehicle stops at the given stopping place. More...
 
virtual bool stopsAtEdge (const MSEdge *edge) const =0
 Returns whether the vehicle stops at the given edge. More...
 
virtual const MSEdgesuccEdge (int nSuccs) const =0
 Returns the nSuccs'th successor of edge the vehicle is currently at. More...
 
virtual bool wasRemoteControlled (SUMOTime lookBack=DELTA_T) const =0
 Returns the information whether the vehicle is fully controlled via TraCI. More...
 
virtual ~SUMOVehicle ()
 Destructor. More...
 

state io

virtual void saveState (OutputDevice &out)=0
 Saves the states of a vehicle. More...
 
virtual void loadState (const SUMOSAXAttributes &attrs, const SUMOTime offset)=0
 Loads the state of this vehicle from the given description. More...
 

Detailed Description

Representation of a vehicle.

Definition at line 60 of file SUMOVehicle.h.

Member Typedef Documentation

◆ NumericalID

typedef long long int SUMOVehicle::NumericalID

Definition at line 62 of file SUMOVehicle.h.

Constructor & Destructor Documentation

◆ ~SUMOVehicle()

virtual SUMOVehicle::~SUMOVehicle ( )
inlinevirtual

Destructor.

Definition at line 65 of file SUMOVehicle.h.

Member Function Documentation

◆ addContainer()

virtual void SUMOVehicle::addContainer ( MSTransportable container)
pure virtual

Adds a container to this vehicle.

May do nothing since containers are not supported by default

Parameters
[in]containerThe container to add

Implemented in MSVehicle, and MSBaseVehicle.

Referenced by MSTransportableControl::loadAnyWaiting().

◆ addPerson()

virtual void SUMOVehicle::addPerson ( MSTransportable person)
pure virtual

Adds a person to this vehicle.

May do nothing since persons are not supported by default

Parameters
[in]personThe person to add

Implemented in MSVehicle, and MSBaseVehicle.

Referenced by MSTransportableControl::boardAnyWaiting().

◆ addStop()

virtual bool SUMOVehicle::addStop ( const SUMOVehicleParameter::Stop stopPar,
std::string &  errorMsg,
SUMOTime  untilOffset = 0,
bool  collision = false,
ConstMSEdgeVector::const_iterator *  searchStart = 0 
)
pure virtual

Adds a stop.

The stop is put into the sorted list.

Parameters
[in]stopThe stop to add
Returns
Whether the stop could be added

Implemented in MSVehicle, and MEVehicle.

Referenced by MSBaseVehicle::addStops(), and MSDevice_ToC::triggerMRM().

◆ getAcceleration()

◆ getAccumulatedWaitingTime()

virtual SUMOTime SUMOVehicle::getAccumulatedWaitingTime ( ) const
pure virtual

Implemented in MSVehicle, and MEVehicle.

Referenced by MSTriggeredRerouter::notifyEnter().

◆ getAngle()

virtual double SUMOVehicle::getAngle ( ) const
pure virtual

Get the vehicle's angle.

Returns
The angle of the vehicle (in degree)

Implements SUMOTrafficObject.

Implemented in MSVehicle, GUIMEVehicle, GUIVehicle, and MEVehicle.

Referenced by MSDevice_Battery::notifyMove(), MSEmissionExport::write(), MSFCDExport::write(), and MSFullExport::writeVehicles().

◆ getArrivalPos()

virtual double SUMOVehicle::getArrivalPos ( ) const
pure virtual

Returns this vehicle's desired arrivalPos for its current route (may change on reroute)

Returns
This vehicle's real arrivalPos

Implemented in MSBaseVehicle.

Referenced by MSTriggeredRerouter::notifyEnter(), MSDevice_Tripinfo::notifyLeave(), MSTriggeredRerouter::rerouteParkingArea(), and MSDevice_Vehroutes::writeOutput().

◆ getBackPositionOnLane()

virtual double SUMOTrafficObject::getBackPositionOnLane ( const MSLane lane) const
pure virtualinherited

Get the vehicle's back position along the given lane.

Returns
The position of the vehicle (in m from the given lane's begin)

Implemented in MSVehicle, MEVehicle, and MSTransportable.

Referenced by MSE3Collector::MSE3EntryReminder::notifyEnter(), MSInductLoop::notifyEnter(), MSE3Collector::MSE3LeaveReminder::notifyEnter(), and MSE2Collector::notifyEnter().

◆ getBrakeGap()

virtual double SUMOVehicle::getBrakeGap ( ) const
pure virtual

get distance for coming to a stop (used for rerouting checks)

Implemented in MSVehicle, and MEVehicle.

Referenced by MSTriggeredRerouter::rerouteParkingArea().

◆ getChosenSpeedFactor()

virtual double SUMOTrafficObject::getChosenSpeedFactor ( ) const
pure virtualinherited

◆ getContainerNumber()

virtual int SUMOVehicle::getContainerNumber ( ) const
pure virtual

Returns the number of containers.

Returns
The number of contaiers on-board

Implemented in MSBaseVehicle.

Referenced by MSTransportableControl::loadAnyWaiting().

◆ getContainers()

virtual const std::vector<MSTransportable*>& SUMOVehicle::getContainers ( ) const
pure virtual

retrieve riding containers

Implemented in MSBaseVehicle.

Referenced by MSFCDExport::write().

◆ getCurrentRouteEdge()

virtual const ConstMSEdgeVector::const_iterator& SUMOVehicle::getCurrentRouteEdge ( ) const
pure virtual

Returns an iterator pointing to the current edge in this vehicles route.

Returns
The current route pointer

Implemented in MSBaseVehicle.

Referenced by MSDevice_SSM::findFoeConflictLane(), MSRailSignal::LinkInfo::getDriveWay(), MSRailSignal::hasOncomingRailTraffic(), MSTriggeredRerouter::notifyEnter(), and MSDevice_Vehroutes::writeOutput().

◆ getDepartDelay()

virtual SUMOTime SUMOVehicle::getDepartDelay ( ) const
pure virtual

◆ getDepartPos()

virtual double SUMOVehicle::getDepartPos ( ) const
pure virtual

Returns this vehicle's real departure position.

Returns
This vehicle's real departure position

Implemented in MSBaseVehicle.

Referenced by MSDevice_Tripinfo::generateOutput(), and MSDevice_Vehroutes::writeOutput().

◆ getDeparture()

virtual SUMOTime SUMOVehicle::getDeparture ( ) const
pure virtual

Returns this vehicle's real departure time.

Returns
This vehicle's real departure time

Implemented in MSBaseVehicle.

Referenced by MSDevice_Tripinfo::generateOutput(), MSVehicleControl::vehicleDeparted(), MSDevice_Vehroutes::writeOutput(), and MSAmitranTrajectories::writeVehicle().

◆ getDevice()

virtual MSVehicleDevice* SUMOVehicle::getDevice ( const std::type_info &  type) const
pure virtual

◆ getDevices()

virtual const std::vector<MSVehicleDevice*>& SUMOVehicle::getDevices ( ) const
pure virtual

Returns this vehicle's devices.

Returns
This vehicle's devices

Implemented in MSBaseVehicle.

Referenced by MSStateHandler::closeVehicle(), and MSDevice_Tripinfo::generateOutput().

◆ getEdge()

◆ getEmissionParameters()

virtual const std::map<int, double>* SUMOVehicle::getEmissionParameters ( ) const
pure virtual

Returns the vehicle's emission model parameter.

Returns
The vehicle's emission parameters

Implemented in MSBaseVehicle.

Referenced by MSMeanData_Emissions::MSLaneMeanDataValues::notifyMoveInternal(), MSDevice_Emissions::notifyMoveInternal(), MSEmissionExport::write(), and MSFullExport::writeVehicles().

◆ getID()

virtual const std::string& SUMOTrafficObject::getID ( ) const
pure virtualinherited

Get the vehicle's ID.

Returns
The the ID of the vehicle

Implemented in MSTransportable, and MSBaseVehicle.

Referenced by MSChargingStation::addChargeValueForOutput(), MSDevice_ToC::awarenessRecoveryStep(), MSLink::blockedByFoe(), MSDevice_Transportable::buildVehicleDevices(), MSDevice_Battery::buildVehicleDevices(), MSDevice_Tripinfo::buildVehicleDevices(), MSDevice_Bluelight::buildVehicleDevices(), MSDevice_Example::buildVehicleDevices(), MSDevice_FCD::buildVehicleDevices(), MSDevice_BTreceiver::buildVehicleDevices(), MSDevice_BTsender::buildVehicleDevices(), MSDevice_Vehroutes::buildVehicleDevices(), MSDevice_DriverState::buildVehicleDevices(), MSDevice_Emissions::buildVehicleDevices(), MSDevice_Routing::buildVehicleDevices(), MSDevice_ToC::buildVehicleDevices(), MSDevice_SSM::buildVehicleDevices(), MSE2Collector::calculateTimeLossAndTimeOnDetector(), MSDevice_ToC::checkDynamicToC(), MSInductLoop::collectVehiclesOnDet(), MSDevice_ToC::deactivateDeliberateLCs(), MSVehicleControl::deleteVehicle(), MSE3Collector::detectorUpdate(), MSE3Collector::enter(), MSVTypeProbe::execute(), MSDevice_Tripinfo::generateOutput(), MSDevice::getBoolParam(), MSDevice_SSM::getDetectionRange(), MSDevice_SSM::getExtraTime(), MSDevice::getFloatParam(), MSParkingArea::getLastFreePosWithReservation(), MSDevice_SSM::getMeasuresAndThresholds(), MSDevice_SSM::getOutputFilename(), MSDevice_ToC::getParameter(), MSDevice::getStringParam(), libsumo::Person::getVehicle(), PolygonDynamics::initTrackedPosition(), MSEdge::insertVehicle(), MSTransportable::Stage_Driving::isWaitingFor(), MSE3Collector::leave(), MSInductLoop::leaveDetectorByMove(), MSE3Collector::leaveFront(), MSE2Collector::makeMoveNotification(), MSE2Collector::makeVehicleInfo(), MSDevice_ToC::MRMExecutionStep(), MSDevice_ToC::MSDevice_ToC(), MSE3Collector::MSE3EntryReminder::notifyEnter(), MSMeanData::MeanDataValues::notifyEnter(), MSDevice_BTsender::notifyEnter(), MSDevice_BTreceiver::notifyEnter(), MSMeanData_Net::MSLaneMeanDataValues::notifyEnter(), MSTriggeredRerouter::notifyEnter(), MSE3Collector::MSE3LeaveReminder::notifyEnter(), MSMeanData::MeanDataValueTracker::notifyEnter(), MSE2Collector::notifyEnter(), MSE3Collector::MSE3EntryReminder::notifyLeave(), MSDevice_BTsender::notifyLeave(), MSDevice_BTreceiver::notifyLeave(), MSE3Collector::MSE3LeaveReminder::notifyLeave(), MSE2Collector::notifyLeave(), MSDevice_Battery::notifyMove(), MSDevice_Example::notifyMove(), MSDevice_Bluelight::notifyMove(), MSE3Collector::MSE3EntryReminder::notifyMove(), MSMeanData::MeanDataValues::notifyMove(), MSDevice_BTsender::notifyMove(), MSDevice_BTreceiver::notifyMove(), MSE3Collector::MSE3LeaveReminder::notifyMove(), MSE2Collector::notifyMove(), MSMeanData_Net::MSLaneMeanDataValues::notifyMoveInternal(), MSLink::opened(), PolygonDynamics::PolygonDynamics(), MSLink::removeApproaching(), MSDevice_SSM::requestsTrajectories(), MSDevice_ToC::requestToC(), MSRailSignal::LinkInfo::reroute(), MSTriggeredRerouter::rerouteParkingArea(), MSDevice_ToC::resetDeliberateLCs(), MSLink::setApproaching(), MSTransportable::Stage_Trip::setArrived(), MSTransportable::Stage_Driving::setVehicle(), MSStopOut::stopEnded(), MSStopOut::stopStarted(), MSLane::succLinkSec(), MSDevice_ToC::switchHolderType(), MSDevice_ToC::ToCPreparationStep(), MSDevice_ToC::triggerDownwardToC(), MSDevice_ToC::triggerMRM(), MSDevice_ToC::triggerUpwardToC(), PolygonDynamics::update(), MSDevice_SSM::useGeoCoords(), MSDynamicShapeUpdater::vehicleStateChanged(), TraCIServer::vehicleStateChanged(), libsumo::Helper::VehicleStateListener::vehicleStateChanged(), MSEmissionExport::write(), MSFCDExport::write(), MSInstantInductLoop::write(), MSDevice_Vehroutes::writeOutput(), MSDevice_ToC::writeOutput(), MSAmitranTrajectories::writeVehicle(), MSFullExport::writeVehicles(), and MSDevice_Transportable::~MSDevice_Transportable().

◆ getImpatience()

virtual double SUMOVehicle::getImpatience ( ) const
pure virtual

Returns this vehicles impatience.

Implemented in MSBaseVehicle.

◆ getLane()

◆ getLateralPositionOnLane()

virtual double SUMOVehicle::getLateralPositionOnLane ( ) const
pure virtual

Get the vehicle's lateral position on the lane.

Returns
The lateral position of the vehicle (in m relative to the centerline of the lane)

Implemented in MSVehicle, and MSBaseVehicle.

Referenced by MSLink::opened().

◆ getMaxSpeed()

virtual double SUMOTrafficObject::getMaxSpeed ( ) const
pure virtualinherited

Returns the vehicle's maximum speed.

Returns
The vehicle's maximum speed

Implemented in MSTransportable, and MSBaseVehicle.

Referenced by MSLane::getVehicleMaxSpeed().

◆ getNextParkingArea()

virtual MSParkingArea* SUMOVehicle::getNextParkingArea ( )
pure virtual

returns the next imminent stop in the stop queue

Returns
the upcoming stop

Implemented in MSVehicle, and MEVehicle.

Referenced by MSTriggeredRerouter::notifyEnter(), and MSTriggeredRerouter::rerouteParkingArea().

◆ getNumberReroutes()

virtual int SUMOVehicle::getNumberReroutes ( ) const
pure virtual

Returns the number of new routes this vehicle got.

Returns
the number of new routes this vehicle got

Implemented in MSBaseVehicle.

Referenced by MSDevice_Tripinfo::generateOutput(), and MSDevice_Vehroutes::writeXMLRoute().

◆ getNumericalID()

virtual NumericalID SUMOVehicle::getNumericalID ( ) const
pure virtual

return the numerical ID which is only for internal usage

Implemented in MSBaseVehicle.

Referenced by MSVehicleDevice::getNumericalID().

◆ getParameter()

◆ getPersonIDList()

virtual std::vector<std::string> SUMOVehicle::getPersonIDList ( ) const
pure virtual

Returns the list of persons.

Returns
The list of passengers on-board

Implemented in MSBaseVehicle.

◆ getPersonNumber()

virtual int SUMOVehicle::getPersonNumber ( ) const
pure virtual

Returns the number of persons.

Returns
The number of passengers on-board

Implemented in MSBaseVehicle.

Referenced by MSTransportableControl::boardAnyWaiting().

◆ getPersons()

virtual const std::vector<MSTransportable*>& SUMOVehicle::getPersons ( ) const
pure virtual

retrieve riding persons

Implemented in MSBaseVehicle.

Referenced by MSTriggeredRerouter::notifyEnter(), and MSFCDExport::write().

◆ getPosition()

virtual Position SUMOTrafficObject::getPosition ( const double  offset = 0) const
pure virtualinherited

◆ getPositionOnLane()

◆ getPreviousSpeed()

virtual double SUMOTrafficObject::getPreviousSpeed ( ) const
pure virtualinherited

◆ getRNG()

virtual std::mt19937* SUMOVehicle::getRNG ( ) const
pure virtual

Returns the associated RNG for this vehicle.

Returns
The vehicle's associated RNG

Implemented in MSBaseVehicle.

Referenced by MSLink::blockedAtTime(), and MSTriggeredRerouter::notifyEnter().

◆ getRNGIndex()

virtual int SUMOVehicle::getRNGIndex ( ) const
pure virtual
Returns
The index of the vehicle's associated RNG

Implemented in MSBaseVehicle.

Referenced by MSTriggeredRerouter::notifyEnter(), and MSTriggeredRerouter::rerouteParkingArea().

◆ getRoute()

◆ getSlope()

virtual double SUMOTrafficObject::getSlope ( ) const
pure virtualinherited

◆ getSpeed()

◆ getStopIndices()

virtual std::vector<std::pair<int, double> > SUMOVehicle::getStopIndices ( ) const
pure virtual

return list of route indices and stop positions for the remaining stops

Implemented in MSVehicle, and MEVehicle.

Referenced by MSTriggeredRerouter::rerouteParkingArea().

◆ getVClass()

virtual SUMOVehicleClass SUMOTrafficObject::getVClass ( ) const
pure virtualinherited

Returns the vehicle's access class.

Returns
The vehicle's access class

Implemented in MSTransportable, and MSBaseVehicle.

Referenced by MSLane::getVehicleMaxSpeed(), MSRoutingEngine::initRouter(), MSEdge::prohibits(), MSTransportable::Stage_Driving::setVehicle(), and MSVehicleControl::vehicleDeparted().

◆ getVehicleType()

virtual const MSVehicleType& SUMOTrafficObject::getVehicleType ( ) const
pure virtualinherited

Returns the vehicle's type.

Returns
The vehicle's type

Implemented in MSTransportable, and MSBaseVehicle.

Referenced by MSChargingStation::addChargeValueForOutput(), MSLink::blockedAtTime(), MSLink::blockedByFoe(), MSTransportableControl::boardAnyWaiting(), MSDevice_Battery::buildVehicleDevices(), MSDevice_Bluelight::buildVehicleDevices(), MSDevice_Example::buildVehicleDevices(), MSInductLoop::collectVehiclesOnDet(), MSVTypeProbe::execute(), MSStoppingPlace::fits(), MSDevice_Tripinfo::generateOutput(), MSDevice::getBoolParam(), MSDevice_SSM::getDetectionRange(), MSDevice_SSM::getExtraTime(), MSDevice::getFloatParam(), MSStoppingPlace::getLastFreePos(), MSParkingArea::getLastFreePos(), MSParkingArea::getLastFreePosWithReservation(), MSDevice_SSM::getMeasuresAndThresholds(), MSDevice_ToC::getOutputFilename(), MSDevice_SSM::getOutputFilename(), libsumo::Person::getStage(), MSDevice::getStringParam(), MSTriggeredRerouter::getWeight(), MSEdge::insertVehicle(), MSInductLoop::leaveDetectorByMove(), MSTransportableControl::loadAnyWaiting(), MSE2Collector::makeVehicleInfo(), MSDevice_ToC::MSDevice_ToC(), MSE3Collector::MSE3EntryReminder::notifyEnter(), MSMeanData_Amitran::MSLaneMeanDataValues::notifyEnter(), MSDevice_Bluelight::notifyMove(), MSInstantInductLoop::notifyMove(), MSDevice_Emissions::notifyMove(), MSMeanData::MeanDataValues::notifyMove(), MSInductLoop::notifyMove(), MSE3Collector::MSE3LeaveReminder::notifyMove(), MSE2Collector::notifyMove(), MSMeanData_Emissions::MSLaneMeanDataValues::notifyMoveInternal(), MSMeanData_Harmonoise::MSLaneMeanDataValues::notifyMoveInternal(), MSDevice_Emissions::notifyMoveInternal(), MSMeanData_Amitran::MSLaneMeanDataValues::notifyMoveInternal(), MSMeanData_Net::MSLaneMeanDataValues::notifyMoveInternal(), MSDevice_SSM::requestsTrajectories(), MSLink::setApproaching(), MSStopOut::stopEnded(), MSLane::succLinkSec(), MSDevice_SSM::useGeoCoords(), MSDetectorFileOutput::vehicleApplies(), MSTriggeredRerouter::vehicleApplies(), MSVehicleControl::vehicleDeparted(), MSEmissionExport::write(), MSFCDExport::write(), MSInstantInductLoop::write(), MSDevice_Vehroutes::writeOutput(), MSAmitranTrajectories::writeVehicle(), and MSFullExport::writeVehicles().

◆ getWaitingTime()

virtual SUMOTime SUMOTrafficObject::getWaitingTime ( ) const
pure virtualinherited

◆ hasArrived()

virtual bool SUMOTrafficObject::hasArrived ( ) const
pure virtualinherited

Returns whether this vehicle has arrived.

Implemented in MSTransportable, MSBaseVehicle, MSVehicle, and MEVehicle.

Referenced by MSMeanData::MeanDataValues::notifyMove().

◆ hasDeparted()

◆ hasValidRoute()

virtual bool SUMOVehicle::hasValidRoute ( std::string &  msg,
const MSRoute route = 0 
) const
pure virtual

Validates the current or given route.

Parameters
[out]msgDescription why the route is not valid (if it is the case)
[in]routeThe route to check (or 0 if the current route shall be checked)
Returns
Whether the vehicle's current route is valid

Implemented in MSBaseVehicle.

◆ isFrontOnLane()

virtual bool SUMOVehicle::isFrontOnLane ( const MSLane ) const
pure virtual

Returns the information whether the front of the vehhicle is on the given lane.

Returns
Whether the vehicle's front is on that lane

Implemented in MSVehicle, and MSBaseVehicle.

◆ isOnRoad()

◆ isParking()

virtual bool SUMOVehicle::isParking ( ) const
pure virtual

Returns the information whether the vehicle is parked.

Returns
Whether the vehicle is parked

Implemented in MSVehicle, and MEVehicle.

Referenced by GUIVehicleControl::insertVehicleIDs(), libsumo::Vehicle::isVisible(), and MSFCDExport::write().

◆ isRemoteControlled()

virtual bool SUMOVehicle::isRemoteControlled ( ) const
pure virtual

Returns the information whether the vehicle is fully controlled via TraCI.

Returns
Whether the vehicle is remote-controlled

Implemented in MSVehicle, and MSBaseVehicle.

Referenced by MSVehicleControl::getHaltingVehicleNo(), MSVehicleControl::getVehicleMeanSpeeds(), and MSFCDExport::write().

◆ isSelected()

virtual bool SUMOVehicle::isSelected ( ) const
pure virtual

whether this vehicle is selected in the GUI

Implemented in MSBaseVehicle, and GUIVehicle.

◆ isStopped()

virtual bool SUMOTrafficObject::isStopped ( ) const
pure virtualinherited

Returns whether the vehicle is at a stop.

Returns
Whether the has stopped

Implemented in MSVehicle, MSTransportable, and MEVehicle.

Referenced by MSVehicleControl::getVehicleMeanSpeeds(), MSDevice_Transportable::notifyMove(), MSDevice_Tripinfo::notifyMove(), and MSDevice_Transportable::removeTransportable().

◆ isStoppedInRange()

virtual bool SUMOVehicle::isStoppedInRange ( const double  pos,
const double  tolerance 
) const
pure virtual

Returns whether the vehicle is stopped in the range of the given position.

Implemented in MSVehicle, and MEVehicle.

◆ isStoppedTriggered()

virtual bool SUMOVehicle::isStoppedTriggered ( ) const
pure virtual

Returns whether the vehicle is at a stop and waiting for a person or container to continue.

Implemented in MSVehicle, and MEVehicle.

◆ isVehicle()

◆ loadState()

virtual void SUMOVehicle::loadState ( const SUMOSAXAttributes attrs,
const SUMOTime  offset 
)
pure virtual

Loads the state of this vehicle from the given description.

Implemented in MSVehicle, and MEVehicle.

Referenced by MSStateHandler::closeVehicle().

◆ onDepart()

virtual void SUMOVehicle::onDepart ( )
pure virtual

Called when the vehicle is inserted into the network.

Sets optional information about departure time, informs the vehicle control about a further running vehicle.

Implemented in MSBaseVehicle.

◆ remainingStopDuration()

virtual SUMOTime SUMOVehicle::remainingStopDuration ( ) const
pure virtual

Returns the remaining stop duration for a stopped vehicle or 0.

Implemented in MSVehicle, and MEVehicle.

◆ removeTransportable()

virtual void SUMOVehicle::removeTransportable ( MSTransportable t)
pure virtual

removes a person or container

Implemented in MSBaseVehicle.

Referenced by MSTransportable::~MSTransportable().

◆ replaceParameter()

virtual void SUMOVehicle::replaceParameter ( const SUMOVehicleParameter newParameter)
pure virtual

Replaces the vehicle's parameter.

Implemented in MSBaseVehicle.

Referenced by MSTriggeredRerouter::notifyEnter().

◆ replaceParkingArea()

virtual bool SUMOVehicle::replaceParkingArea ( MSParkingArea parkingArea,
std::string &  errorMsg 
)
pure virtual

Replaces a stop.

The stop replace the next stop into the sorted list.

Parameters
[in]stopThe stop to add
Returns
Whether the stop could be added

Implemented in MSVehicle, and MEVehicle.

Referenced by MSTriggeredRerouter::notifyEnter().

◆ replaceRoute()

virtual bool SUMOVehicle::replaceRoute ( const MSRoute route,
const std::string &  info,
bool  onInit = false,
int  offset = 0,
bool  addStops = true,
bool  removeStops = true 
)
pure virtual

Replaces the current route by the given one.

Implemented in MEVehicle, and MSVehicle.

Referenced by MSTriggeredRerouter::notifyEnter(), MSDevice_Routing::preInsertionReroute(), and MSBaseVehicle::replaceRouteEdges().

◆ replaceRouteEdges()

virtual bool SUMOVehicle::replaceRouteEdges ( ConstMSEdgeVector edges,
double  cost,
double  savings,
const std::string &  info,
bool  onInit = false,
bool  check = false,
bool  removeStops = true 
)
pure virtual

Replaces the current route by the given edges.

It is possible that the new route is not accepted, if a) it does not contain the vehicle's current edge, or b) something fails on insertion into the routes container (see in-line comments).

Parameters
[in]edgesThe new list of edges to pass
[in]onInitWhether the vehicle starts with this route
[in]checkWhether the route should be checked for validity
[in]removeStopsWhether stops should be removed if they do not fit onto the new route
Returns
Whether the new route was accepted

Implemented in MSBaseVehicle.

Referenced by MSTriggeredRerouter::notifyEnter(), and MSTransportable::Stage_Trip::setArrived().

◆ reroute()

virtual void SUMOVehicle::reroute ( SUMOTime  t,
const std::string &  info,
SUMOAbstractRouter< MSEdge, SUMOVehicle > &  router,
const bool  onInit = false,
const bool  withTaz = false,
const bool  silent = false 
)
pure virtual

Performs a rerouting using the given router.

Tries to find a new route between the current edge and the destination edge, first. Tries to replace the current route by the new one using replaceRoute.

Parameters
[in]tThe time for which the route is computed
[in]routerThe router to use
See also
replaceRoute

Implemented in MSBaseVehicle.

Referenced by MSRoutingEngine::reroute().

◆ saveState()

virtual void SUMOVehicle::saveState ( OutputDevice out)
pure virtual

Saves the states of a vehicle.

Implemented in MSVehicle, MSBaseVehicle, and MEVehicle.

◆ setArrivalPos()

virtual void SUMOVehicle::setArrivalPos ( double  arrivalPos)
pure virtual

Sets this vehicle's desired arrivalPos for its current route.

Implemented in MSBaseVehicle.

Referenced by MSTriggeredRerouter::notifyEnter(), and MSTransportable::Stage_Trip::setArrived().

◆ setChosenSpeedFactor()

virtual void SUMOVehicle::setChosenSpeedFactor ( const double  factor)
pure virtual

◆ stopsAt()

virtual bool SUMOVehicle::stopsAt ( MSStoppingPlace stop) const
pure virtual

Returns whether the vehicle stops at the given stopping place.

Implemented in MSVehicle, and MEVehicle.

Referenced by MSTransportable::Stage_Driving::isWaitingFor().

◆ stopsAtEdge()

virtual bool SUMOVehicle::stopsAtEdge ( const MSEdge edge) const
pure virtual

Returns whether the vehicle stops at the given edge.

Implemented in MSVehicle, and MEVehicle.

Referenced by MSTransportable::Stage_Driving::isWaitingFor().

◆ succEdge()

virtual const MSEdge* SUMOVehicle::succEdge ( int  nSuccs) const
pure virtual

Returns the nSuccs'th successor of edge the vehicle is currently at.

If the rest of the route (counted from the current edge) than nSuccs, 0 is returned.

Parameters
[in]nSuccsThe number of edge to look forward
Returns
The nSuccs'th following edge in the vehicle's route

Implemented in MSBaseVehicle.

Referenced by MSLane::succLinkSec().

◆ wasRemoteControlled()

virtual bool SUMOVehicle::wasRemoteControlled ( SUMOTime  lookBack = DELTA_T) const
pure virtual

Returns the information whether the vehicle is fully controlled via TraCI.

Returns
Whether the vehicle was remote-controlled within the given time range

Implemented in MSVehicle, and MSBaseVehicle.

Referenced by libsumo::Vehicle::isVisible().


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