![]() |
Eclipse SUMO - Simulation of Urban MObility
|
#include <MSTransportable.h>
Public Member Functions | |
virtual void | abort (MSTransportable *) |
abort this stage (TraCI) More... | |
virtual void | beginEventOutput (const MSTransportable &p, SUMOTime t, OutputDevice &os) const |
Called for writing the events output. More... | |
Stage * | clone () const |
virtual void | endEventOutput (const MSTransportable &p, SUMOTime t, OutputDevice &os) const |
Called for writing the events output (end of an action) More... | |
double | getAngle (SUMOTime now) const |
returns the angle of the transportable More... | |
double | getArrivalPos () const |
SUMOTime | getDeparted () const |
get departure time of stage More... | |
const MSEdge * | getDestination () const |
returns the destination edge More... | |
MSStoppingPlace * | getDestinationStop () const |
returns the destination stop (if any) More... | |
double | getDistance () const |
get travel distance in this stage More... | |
const MSEdge * | getEdge () const |
Returns the current edge. More... | |
double | getEdgeAngle (const MSEdge *e, double at) const |
get angle of the edge at a certain position More... | |
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 MSEdge * | getFromEdge () const |
Position | getLanePosition (const MSLane *lane, double at, double offset) const |
get position on lane at length at with orthogonal offset More... | |
const MSStoppingPlace * | getOriginStop () const |
returns the origin stop (if any). only needed for Stage_Trip 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 |
return (brief) string representation of the current stage More... | |
std::string | getStageSummary () const |
return string summary of the current stage More... | |
StageType | getStageType () const |
virtual SUMOVehicle * | getVehicle () 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 SUMOVehicle *vehicle) const |
Whether the transportable waits for the given vehicle. More... | |
virtual void | proceed (MSNet *net, MSTransportable *transportable, SUMOTime now, Stage *previous) |
proceeds to the next step More... | |
virtual void | routeOutput (OutputDevice &os, const bool withRouteLength) const |
Called on writing vehroute output. 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... | |
void | setDestination (const MSEdge *newDestination, MSStoppingPlace *newDestStop) |
void | setOrigin (const MSEdge *origin) |
change origin for parking area rerouting More... | |
virtual void | setSpeed (double) |
sets the walking speed (ignored in other stages) More... | |
Stage_Trip (const MSEdge *origin, MSStoppingPlace *fromStop, const MSEdge *destination, MSStoppingPlace *toStop, const SUMOTime duration, const SVCPermissions modeSet, const std::string &vTypes, const double speed, const double walkFactor, const double departPosLat, const bool hasArrivalPos, const double arrivalPos) | |
constructor More... | |
virtual void | tripInfoOutput (OutputDevice &os, const MSTransportable *const transportable) const |
Called on writing tripinfo output. More... | |
virtual | ~Stage_Trip () |
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 MSEdge * | myDestination |
the next edge to reach by getting transported More... | |
MSStoppingPlace * | myDestinationStop |
the stop to reach by getting transported (if any) More... | |
StageType | myType |
The type of this stage. More... | |
Private Member Functions | |
Stage_Trip & | operator= (const Stage_Trip &) |
Invalidated assignment operator. More... | |
Stage_Trip (const Stage_Trip &) | |
Invalidated copy constructor. More... | |
Private Attributes | |
double | myDepartPos |
The depart position. More... | |
const double | myDepartPosLat |
The lateral depart position. More... | |
SUMOTime | myDuration |
the time the trip should take (applies to only walking) More... | |
const bool | myHaveArrivalPos |
whether an arrivalPos was in the input More... | |
const SVCPermissions | myModeSet |
The allowed modes of transportation. More... | |
const MSEdge * | myOrigin |
the origin edge More... | |
const MSStoppingPlace * | myOriginStop |
the origin edge More... | |
const double | mySpeed |
The walking speed. More... | |
const std::string | myVTypes |
The possible vehicles to use. More... | |
const double | myWalkFactor |
The factor to apply to walking durations. More... | |
A "placeholder" stage storing routing info which will result in real stages when routed
Definition at line 233 of file MSTransportable.h.
MSTransportable::Stage_Trip::Stage_Trip | ( | const MSEdge * | origin, |
MSStoppingPlace * | fromStop, | ||
const MSEdge * | destination, | ||
MSStoppingPlace * | toStop, | ||
const SUMOTime | duration, | ||
const SVCPermissions | modeSet, | ||
const std::string & | vTypes, | ||
const double | speed, | ||
const double | walkFactor, | ||
const double | departPosLat, | ||
const bool | hasArrivalPos, | ||
const double | arrivalPos | ||
) |
constructor
Definition at line 153 of file MSTransportable.cpp.
|
virtual |
destructor
Definition at line 171 of file MSTransportable.cpp.
|
private |
Invalidated copy constructor.
|
inlinevirtualinherited |
abort this stage (TraCI)
Reimplemented in MSTransportable::Stage_Driving, MSTransportable::Stage_Waiting, and MSPerson::MSPersonStage_Walking.
Definition at line 125 of file MSTransportable.h.
Referenced by GUIPerson::GUIPersonPopupMenu::onCmdRemoveObject().
|
virtual |
Called for writing the events output.
[in] | os | The stream to write the information into |
IOError | not yet implemented |
Implements MSTransportable::Stage.
Definition at line 342 of file MSTransportable.cpp.
|
virtual |
Implements MSTransportable::Stage.
Definition at line 174 of file MSTransportable.cpp.
|
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 MSTransportable::Stage.
Definition at line 347 of file MSTransportable.cpp.
|
virtual |
returns the angle of the transportable
Implements MSTransportable::Stage.
Definition at line 189 of file MSTransportable.cpp.
References MSNet::getInstance(), MSNet::lefthand(), and M_PI.
|
inlineinherited |
Definition at line 95 of file MSTransportable.h.
References MSTransportable::Stage::myArrivalPos.
Referenced by libsumo::Person::getStage(), GUIPerson::getStageArrivalPos(), MSRouteHandler::parseWalkPositions(), MSTransportable::rerouteParkingArea(), libsumo::Person::rerouteTraveltime(), and setArrived().
|
inherited |
get departure time of stage
Definition at line 109 of file MSTransportable.cpp.
|
inherited |
returns the destination edge
Definition at line 58 of file MSTransportable.cpp.
Referenced by MSPModel_Striping::moveInDirectionOnLane(), MSRouteHandler::parseWalkPositions(), MSPerson::proceed(), and MSTransportable::rerouteParkingArea().
|
inlineinherited |
returns the destination stop (if any)
Definition at line 86 of file MSTransportable.h.
References MSTransportable::Stage::myDestinationStop.
Referenced by libsumo::Person::getStage(), MSPModel_Striping::moveInDirectionOnLane(), GUIPerson::GUIPersonPopupMenu::onCmdRemoveObject(), MSRouteHandler::parseWalkPositions(), MSContainer::MSContainerStage_Driving::proceed(), MSContainer::proceed(), MSPerson::MSPersonStage_Driving::proceed(), MSPerson::proceed(), MSTransportable::rerouteParkingArea(), and setArrived().
|
inlinevirtual |
get travel distance in this stage
Implements MSTransportable::Stage.
Definition at line 259 of file MSTransportable.h.
|
virtual |
Returns the current edge.
Reimplemented from MSTransportable::Stage.
Definition at line 196 of file MSTransportable.cpp.
|
inherited |
get angle of the edge at a certain position
Definition at line 134 of file MSTransportable.cpp.
References MSEdge::getLanes().
Referenced by MSPModel_NonInteracting::PState::getAngle(), and CState::getAngle().
|
virtual |
Reimplemented from MSTransportable::Stage.
Definition at line 202 of file MSTransportable.cpp.
|
inherited |
get position on edge e at length at with orthogonal offset
Definition at line 124 of file MSTransportable.cpp.
References MSEdge::getLanes().
|
virtualinherited |
the edges of the current stage
Reimplemented in MSTransportable::Stage_Driving, MSContainer::MSContainerStage_Tranship, and MSPerson::MSPersonStage_Walking.
Definition at line 94 of file MSTransportable.cpp.
References MSTransportable::getDestination().
Referenced by libsumo::Person::getStage(), and libsumo::Person::rerouteTraveltime().
|
virtualinherited |
Reimplemented in MSTransportable::Stage_Driving, MSContainer::MSContainerStage_Tranship, and MSPerson::MSPersonStage_Walking.
Definition at line 70 of file MSTransportable.cpp.
Referenced by MSTransportable::rerouteParkingArea().
|
inherited |
get position on lane at length at with orthogonal offset
Definition at line 129 of file MSTransportable.cpp.
References MSLane::getShape(), MSLane::interpolateLanePosToGeometryPos(), and PositionVector::positionAtOffset().
Referenced by CState::computeTranshipTime(), MSPModel_NonInteracting::PState::getPosition(), and MSPModel_Striping::PState::getPosition().
|
inlinevirtual |
returns the origin stop (if any). only needed for Stage_Trip
Reimplemented from MSTransportable::Stage.
Definition at line 249 of file MSTransportable.h.
References myOriginStop.
returns the position of the transportable
Implements MSTransportable::Stage.
Definition at line 182 of file MSTransportable.cpp.
References MSNet::getInstance(), and MSTransportable::ROADSIDE_OFFSET.
|
virtualinherited |
the speed of the transportable
Reimplemented in MSTransportable::Stage_Driving, MSContainer::MSContainerStage_Tranship, and MSPerson::MSPersonStage_Walking.
Definition at line 88 of file MSTransportable.cpp.
|
inlinevirtual |
return (brief) string representation of the current stage
Implements MSTransportable::Stage.
Definition at line 264 of file MSTransportable.h.
|
virtual |
return string summary of the current stage
Implements MSTransportable::Stage.
Definition at line 352 of file MSTransportable.cpp.
References MSTransportable::getDestination(), and Named::getID().
|
inlineinherited |
Definition at line 111 of file MSTransportable.h.
References MSTransportable::Stage::myType.
Referenced by libsumo::Person::getStage(), MSPerson::MSPersonStage_Driving::proceed(), MSPerson::proceed(), and MSTransportable::rerouteParkingArea().
|
inlinevirtualinherited |
Whether the transportable waits for a vehicle.
Reimplemented in MSTransportable::Stage_Driving.
Definition at line 148 of file MSTransportable.h.
Referenced by libsumo::Person::getStage().
the time this transportable spent waiting
Reimplemented in MSTransportable::Stage_Driving, MSTransportable::Stage_Waiting, MSContainer::MSContainerStage_Tranship, and MSPerson::MSPersonStage_Walking.
Definition at line 82 of file MSTransportable.cpp.
|
inlinevirtualinherited |
Whether the transportable waits for a vehicle.
Reimplemented in MSTransportable::Stage_Driving.
Definition at line 143 of file MSTransportable.h.
|
virtualinherited |
Whether the transportable waits for the given vehicle.
Reimplemented in MSTransportable::Stage_Driving.
Definition at line 119 of file MSTransportable.cpp.
|
private |
Invalidated assignment operator.
|
virtual |
proceeds to the next step
Implements MSTransportable::Stage.
Definition at line 325 of file MSTransportable.cpp.
References MSTransportable::proceed().
|
virtual |
Called on writing vehroute output.
[in] | os | The stream to write the information into |
IOError | not yet implemented |
Implements MSTransportable::Stage.
Definition at line 337 of file MSTransportable.cpp.
|
virtual |
logs end of the step
Reimplemented from MSTransportable::Stage.
Definition at line 208 of file MSTransportable.cpp.
References MSVehicleControl::addVehicle(), MSTransportable::appendStage(), MSVehicleControl::buildVehicle(), IntermodalRouter< E, L, N, V >::compute(), DEFAULT_BIKETYPE_ID, MSVehicleControl::deleteVehicle(), SUMOVehicleParameter::depart, DEPART_POS_GIVEN, DEPART_POS_RANDOM, DEPART_TRIGGERED, SUMOVehicleParameter::departPos, SUMOVehicleParameter::departPosProcedure, MSGlobals::gCheckRoutes, MSStoppingPlace::getAccessPos(), MSTransportable::Stage::getArrivalPos(), MSNet::getCurrentTimeStep(), MSTransportable::Stage::getDestinationStop(), MSTransportable::Stage::getEdge(), MSVehicleType::getID(), MSTransportable::getID(), MSNet::getInstance(), MSNet::getIntermodalRouter(), MSTransportable::getMaxSpeed(), MSTransportable::getNextStage(), MSTransportable::getNumRemainingStages(), MSTransportable::getNumStages(), MSTransportable::getParameter(), MSNet::getStoppingPlace(), MSVehicleType::getVehicleClass(), MSNet::getVehicleControl(), MSVehicleControl::getVType(), StringTokenizer::hasNext(), MSTransportable::myStep, RandHelper::rand(), MSTransportable::Stage::setArrived(), SUMO_TAG_BUS_STOP, SVC_BICYCLE, SVC_IGNORING, SVC_PASSENGER, TIME2STEPS, toString(), VEHPARS_DEPARTPOS_SET, VEHPARS_VTYPE_SET, and WRITE_WARNING.
|
inherited |
logs end of the step
Definition at line 102 of file MSTransportable.cpp.
|
inherited |
Definition at line 140 of file MSTransportable.cpp.
References MSStoppingPlace::getBeginLanePosition(), and MSStoppingPlace::getEndLanePosition().
Referenced by MSTransportable::rerouteParkingArea().
|
inline |
change origin for parking area rerouting
Definition at line 274 of file MSTransportable.h.
References myOrigin.
|
inlinevirtualinherited |
sets the walking speed (ignored in other stages)
Reimplemented in MSPerson::MSPersonStage_Walking.
Definition at line 128 of file MSTransportable.h.
|
virtual |
Called on writing tripinfo output.
[in] | os | The stream to write the information into |
IOError | not yet implemented |
Implements MSTransportable::Stage.
Definition at line 332 of file MSTransportable.cpp.
|
protectedinherited |
the position at which we want to arrive
Definition at line 210 of file MSTransportable.h.
Referenced by MSTransportable::Stage::getArrivalPos(), MSPerson::MSPersonStage_Walking::getArrivalPos(), and MSContainer::MSContainerStage_Tranship::getArrivalPos().
|
protectedinherited |
the time at which this stage ended
Definition at line 216 of file MSTransportable.h.
|
protectedinherited |
the time at which this stage started
Definition at line 213 of file MSTransportable.h.
|
private |
The depart position.
Definition at line 330 of file MSTransportable.h.
|
private |
The lateral depart position.
Definition at line 333 of file MSTransportable.h.
|
protectedinherited |
the next edge to reach by getting transported
Definition at line 204 of file MSTransportable.h.
|
protectedinherited |
the stop to reach by getting transported (if any)
Definition at line 207 of file MSTransportable.h.
Referenced by MSTransportable::Stage::getDestinationStop(), and MSPerson::MSPersonStage_Access::MSPersonStage_Access().
|
private |
the time the trip should take (applies to only walking)
Definition at line 315 of file MSTransportable.h.
|
private |
whether an arrivalPos was in the input
Definition at line 336 of file MSTransportable.h.
|
private |
The allowed modes of transportation.
Definition at line 318 of file MSTransportable.h.
|
private |
|
private |
|
private |
The walking speed.
Definition at line 324 of file MSTransportable.h.
|
protectedinherited |
The type of this stage.
Definition at line 219 of file MSTransportable.h.
Referenced by MSTransportable::Stage::getStageType().
|
private |
The possible vehicles to use.
Definition at line 321 of file MSTransportable.h.
|
private |
The factor to apply to walking durations.
Definition at line 327 of file MSTransportable.h.