39 }
else if (
busstop !=
nullptr) {
55 if (
lane !=
nullptr) {
57 }
else if (
segment !=
nullptr) {
75 }
else if (
busstop !=
nullptr) {
101 tmp.
write(dev,
false);
std::string time2string(SUMOTime t, bool humanReadable)
convert SUMOTime to string (independently of global format setting)
const int STOP_STARTED_SET
@ SUMO_TAG_CHARGING_STATION
A Charging Station.
@ SUMO_TAG_CONTAINER_STOP
A container stop.
@ SUMO_TAG_BUS_STOP
A bus stop.
@ SUMO_TAG_PARKING_AREA
A parking area.
@ SUMO_TAG_OVERHEAD_WIRE_SEGMENT
An overhead wire segment.
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
const MSEdge & getEdge() const
Returns the edge this segment belongs to.
A road/street connecting two junctions.
static bool gUseStopStarted
static bool gUseStopEnded
whether the simulation should replay previous stop times
double getOppositePos(double pos) const
return the corresponding position on the opposite lane
MSEdge & getEdge() const
Returns the lane's edge.
static MSNet * getInstance()
Returns the pointer to the unique instance of MSNet (singleton).
MSStoppingPlace * getStoppingPlace(const std::string &id, const SumoXMLTag category) const
Returns the named stopping place of the given category.
A lane area vehicles can halt at.
double getLastFreePos(const SUMOVehicle &forVehicle, double brakePos=0) const
Returns the last free position on this stop.
void write(OutputDevice &dev) const
Write the current stop configuration (used for state saving)
const MSLane * lane
The lane to stop at (microsim only)
bool triggered
whether an arriving person lets the vehicle continue
bool containerTriggered
whether an arriving container lets the vehicle continue
MSStoppingPlace * containerstop
(Optional) container stop if one is assigned to the stop
double getSpeed() const
return speed for passing waypoint / skipping on-demand stop
bool joinTriggered
whether coupling another vehicle (train) the vehicle continue
bool isOpposite
whether this an opposite-direction stop
SUMOTime getMinDuration(SUMOTime time) const
return minimum stop duration when starting stop at time
void initPars(const SUMOVehicleParameter::Stop &stopPar)
initialize attributes from the given stop parameters
int getStateFlagsOld() const
return flags as used by Vehicle::getStopState
const MESegment * segment
The segment to stop at (mesosim only)
int numExpectedContainer
The number of still expected containers.
bool reached
Information whether the stop has been reached.
bool skipOnDemand
whether the decision to skip this stop has been made
bool isInRange(const double pos, const double tolerance) const
whether the stop is in range of the given position
const MSEdge * getEdge() const
double getReachedThreshold() const
return startPos taking into account opposite stopping
double getEndPos(const SUMOVehicle &veh) const
return halting position for upcoming stop;
int numExpectedPerson
The number of still expected persons.
MSParkingArea * parkingarea
(Optional) parkingArea if one is assigned to the stop
MSStoppingPlace * chargingStation
(Optional) charging station if one is assigned to the stop
std::string getDescription() const
get a short description for showing in the gui
SUMOTime duration
The stopping duration.
SUMOTime getUntil() const
return until / ended time
SUMOTime getArrival() const
return arrival / started time
const SUMOVehicleParameter::Stop pars
The stop parameter.
MSStoppingPlace * busstop
(Optional) bus stop if one is assigned to the stop
MSStoppingPlace * overheadWireSegment
(Optional) overhead wire segment if one is assigned to the stop
double getLastFreePos(const SUMOVehicle &forVehicle, double brakePos=0) const
Returns the last free position on this stop.
const std::string & getID() const
Returns the id.
Static storage of an output device and its base (abstract) implementation.
OutputDevice & writeAttr(const SumoXMLAttr attr, const T &val)
writes a named attribute
bool closeTag(const std::string &comment="")
Closes the most recently opened tag and optionally adds a comment.
void writeParams(OutputDevice &device) const
write Params in the given outputdevice
virtual const MSEdge * getEdge() const =0
Returns the edge the object is currently at.
virtual double getPositionOnLane() const =0
Get the object's position along the lane.
Representation of a vehicle.
virtual double getBrakeGap(bool delayed=false) const =0
get distance for coming to a stop (used for rerouting checks)
Definition of vehicle stop (position and duration)
int getFlags() const
return flags as per Vehicle::getStops
SUMOTime started
the time at which this stop was reached
double speed
the speed at which this stop counts as reached (waypoint mode)
std::string parkingarea
(Optional) parking area if one is assigned to the stop
double startPos
The stopping position start.
std::string chargingStation
(Optional) charging station if one is assigned to the stop
std::string overheadWireSegment
(Optional) overhead line segment if one is assigned to the stop
int parametersSet
Information for the output which parameter were set.
std::string join
the id of the vehicle (train portion) to which this vehicle shall be joined
SUMOTime until
The time at which the vehicle may continue its journey.
std::string actType
act Type (only used by Persons) (used by netedit)
bool triggered
whether an arriving person lets the vehicle continue
void write(OutputDevice &dev, const bool close=true, const bool writeTagAndParents=true) const
Writes the stop as XML.
SUMOTime ended
the time at which this stop was ended
double endPos
The stopping position end.
std::set< std::string > awaitedPersons
IDs of persons the vehicle has to wait for until departing.
std::set< std::string > awaitedContainers
IDs of containers the vehicle has to wait for until departing.
std::string busstop
(Optional) bus stop if one is assigned to the stop
bool joinTriggered
whether an joined vehicle lets this vehicle continue
std::string containerstop
(Optional) container stop if one is assigned to the stop
bool containerTriggered
whether an arriving container lets the vehicle continue
SUMOTime arrival
The (expected) time at which the vehicle reaches the stop.
SUMOTime duration
The stopping duration.