![]() |
SUMO - Simulation of Urban MObility
|
A device which collects info on the vehicle trip (mainly on departure and arrival) More...
#include <MSDevice_Tripinfo.h>
Public Types | |
enum | Notification { NOTIFICATION_DEPARTED, NOTIFICATION_JUNCTION, NOTIFICATION_SEGMENT, NOTIFICATION_LANE_CHANGE, NOTIFICATION_TELEPORT, NOTIFICATION_PARKING, NOTIFICATION_ARRIVED, NOTIFICATION_VAPORIZED, NOTIFICATION_TELEPORT_ARRIVED } |
Definition of a vehicle state. More... | |
Public Member Functions | |
void | addTo (const StoringVisitor &cont) const |
Adds this object to the given container. More... | |
void | generateOutput () const |
Called on writing tripinfo output. More... | |
const std::string & | getDescription () const |
SUMOVehicle & | getHolder () const |
Returns the vehicle that holds this device. More... | |
const std::string & | getID () const |
Returns the id. More... | |
const MSLane * | getLane () const |
Returns the lane the reminder works on. More... | |
virtual void | notifyMoveInternal (SUMOVehicle &veh, SUMOReal timeOnLane, SUMOReal speed) |
Internal notification about the vehicle moves. More... | |
void | setDescription (const std::string &description) |
void | setID (const std::string &newID) |
resets the id More... | |
void | updateStatistics () const |
update tripinfo statistics More... | |
~MSDevice_Tripinfo () | |
Destructor. More... | |
Methods called on vehicle movement / state change, overwriting MSDevice | |
bool | notifyMove (SUMOVehicle &veh, SUMOReal oldPos, SUMOReal newPos, SUMOReal newSpeed) |
Checks for waiting steps when the vehicle moves. More... | |
bool | notifyEnter (SUMOVehicle &veh, MSMoveReminder::Notification reason) |
Saves departure info on insertion. More... | |
bool | notifyLeave (SUMOVehicle &veh, SUMOReal lastPos, MSMoveReminder::Notification reason) |
Saves arrival info. More... | |
Static Public Member Functions | |
static void | buildVehicleDevices (SUMOVehicle &v, std::vector< MSDevice * > &into) |
Build devices for the given vehicle, if needed. More... | |
static void | generateOutputForUnfinished () |
generate output for vehicles which are still in the network More... | |
static SUMOReal | getAvgDepartDelay () |
static SUMOReal | getAvgDuration () |
static SUMOReal | getAvgRouteLength () |
accessors for GUINet-Parameters More... | |
static SUMOReal | getAvgTimeLoss () |
static SUMOReal | getAvgWaitingTime () |
template<class T > | |
static std::string | getIDSecure (const T *obj, const std::string &fallBack="NULL") |
get an identifier for Named-like object which may be Null More... | |
static void | insertOptions (OptionsCont &oc) |
Inserts options for building devices. More... | |
static std::string | printStatistics () |
get statistics for printing to stdout More... | |
Static Protected Member Functions | |
Helper methods for device assignment | |
static void | insertDefaultAssignmentOptions (const std::string &deviceName, const std::string &optionsTopic, OptionsCont &oc) |
Adds common command options that allow to assign devices to vehicles. More... | |
static bool | equippedByDefaultAssignmentOptions (const OptionsCont &oc, const std::string &deviceName, SUMOVehicle &v) |
Determines whether a vehicle should get a certain device. More... | |
Protected Attributes | |
std::string | myDescription |
a description of this moveReminder More... | |
SUMOVehicle & | myHolder |
The vehicle that stores the device. More... | |
std::string | myID |
The name of the object. More... | |
MSLane *const | myLane |
Lane on which the reminder works. More... | |
Private Types | |
typedef std::set< const MSDevice_Tripinfo *, Named::NamedLikeComparatorIdLess< MSDevice_Tripinfo > > | DeviceSet |
devices which may still need to produce output More... | |
Private Member Functions | |
void | computeLengthAndDuration (SUMOReal &routeLength, SUMOTime &duration) const |
MSDevice_Tripinfo (SUMOVehicle &holder, const std::string &id) | |
Constructor. More... | |
MSDevice_Tripinfo () | |
dummy constructor More... | |
MSDevice_Tripinfo (const MSDevice_Tripinfo &) | |
Invalidated copy constructor. More... | |
MSDevice_Tripinfo & | operator= (const MSDevice_Tripinfo &) |
Invalidated assignment operator. More... | |
Private Attributes | |
std::string | myArrivalLane |
The lane the vehicle arrived at. More... | |
SUMOReal | myArrivalPos |
The position on the lane the vehicle arrived at. More... | |
SUMOReal | myArrivalSpeed |
The speed when arriving. More... | |
SUMOTime | myArrivalTime |
The vehicle's arrival time. More... | |
std::string | myDepartLane |
The lane the vehicle departed at. More... | |
SUMOReal | myDepartPos |
The position on the lane the vehicle departed at. More... | |
SUMOReal | myDepartSpeed |
The speed on departure. More... | |
SUMOTime | myTimeLoss |
The time loss when compared to the desired and allowed speed. More... | |
unsigned int | myWaitingSteps |
The overall number of waiting steps. More... | |
Static Private Attributes | |
static DeviceSet | myPendingOutput |
static SUMOTime | myTotalDepartDelay |
static SUMOTime | myTotalDuration |
static SUMOReal | myTotalRouteLength |
static SUMOTime | myTotalTimeLoss |
static SUMOTime | myTotalWaitingTime |
static SUMOReal | myVehicleCount |
global tripinfo statistics More... | |
A device which collects info on the vehicle trip (mainly on departure and arrival)
Each device collects departure time, lane and speed and the same for arrival.
Definition at line 54 of file MSDevice_Tripinfo.h.
|
private |
devices which may still need to produce output
Definition at line 184 of file MSDevice_Tripinfo.h.
|
inherited |
Definition of a vehicle state.
Definition at line 95 of file MSMoveReminder.h.
MSDevice_Tripinfo::~MSDevice_Tripinfo | ( | ) |
|
private |
Constructor.
[in] | holder | The vehicle that holds this device |
[in] | id | The ID of the device |
Definition at line 80 of file MSDevice_Tripinfo.cpp.
|
private |
dummy constructor
Referenced by buildVehicleDevices().
|
private |
Invalidated copy constructor.
|
inlineinherited |
Adds this object to the given container.
Definition at line 126 of file Named.h.
References Named::StoringVisitor::add().
|
static |
Build devices for the given vehicle, if needed.
The options are read and evaluated whether a tripinfo-device shall be built for the given vehicle.
The built device is stored in the given vector.
[in] | v | The vehicle for which a device may be built |
Definition at line 68 of file MSDevice_Tripinfo.cpp.
References SUMOVehicle::getID(), OptionsCont::getOptions(), MSDevice_Tripinfo(), and myPendingOutput.
Referenced by MSDevice::buildVehicleDevices().
|
private |
Definition at line 155 of file MSDevice_Tripinfo.cpp.
References MSRoute::begin(), SUMOVehicle::getCurrentRouteEdge(), MSNet::getCurrentTimeStep(), SUMOVehicle::getDeparture(), MSRoute::getDistanceBetween(), SUMOVehicle::getEdge(), MSLane::getEdge(), MSNet::getInstance(), MSMoveReminder::getLane(), MSEdge::getLength(), SUMOVehicle::getPositionOnLane(), SUMOVehicle::getRoute(), MSGlobals::gUseMesoSim, MSGlobals::gUsingInternalLanes, MSNet::hasInternalLinks(), MSEdge::isInternal(), myArrivalPos, myArrivalTime, myDepartPos, MSDevice::myHolder, NOT_ARRIVED, and SUMOReal.
Referenced by generateOutput(), and updateStatistics().
|
staticprotectedinherited |
Determines whether a vehicle should get a certain device.
[in] | oc | The options container to get the information about assignment from |
[in] | deviceName | The name of the device type |
[in] | v | The vehicle to determine whether it shall be equipped or not |
Definition at line 102 of file MSDevice.cpp.
References TplConvert::_2bool(), OptionsCont::exists(), OptionsCont::getBool(), OptionsCont::getFloat(), SUMOVehicle::getID(), MSNet::getInstance(), OptionsCont::getOptions(), Parameterised::getParameter(), SUMOVehicle::getParameter(), MSVehicleType::getParameter(), MSVehicleControl::getQuota(), OptionsCont::getStringVector(), MSNet::getVehicleControl(), SUMOVehicle::getVehicleType(), OptionsCont::isSet(), Parameterised::knowsParameter(), MSDevice::myExplicitIDs, and RandHelper::rand().
Referenced by MSDevice_Example::buildVehicleDevices(), MSDevice_BTsender::buildVehicleDevices(), MSDevice_BTreceiver::buildVehicleDevices(), MSDevice_Battery::buildVehicleDevices(), MSDevice_Emissions::buildVehicleDevices(), MSDevice_Routing::buildVehicleDevices(), and MSDevice::generateOutput().
|
virtual |
Called on writing tripinfo output.
[in] | os | The stream to write the information into |
IOError | not yet implemented |
Reimplemented from MSDevice.
Definition at line 182 of file MSDevice_Tripinfo.cpp.
References computeLengthAndDuration(), MSRoute::end(), SUMOVehicle::getDepartDelay(), SUMOVehicle::getDeparture(), OutputDevice::getDeviceByOption(), SUMOVehicle::getDevices(), SUMOVehicle::getEdge(), SUMOVehicle::getID(), MSVehicleType::getID(), SUMOVehicle::getNumberReroutes(), OptionsCont::getOptions(), SUMOVehicle::getRoute(), SUMOVehicle::getVehicleType(), myArrivalLane, myArrivalPos, myArrivalSpeed, myArrivalTime, myDepartLane, myDepartPos, myDepartSpeed, MSDevice::myHolder, myPendingOutput, myTimeLoss, myWaitingSteps, OutputDevice::openTag(), SUMOReal, time2string(), updateStatistics(), and OutputDevice::writeAttr().
Referenced by generateOutputForUnfinished().
|
static |
generate output for vehicles which are still in the network
Definition at line 225 of file MSDevice_Tripinfo.cpp.
References OutputDevice::closeTag(), generateOutput(), OutputDevice::getDeviceByOption(), OptionsCont::getOptions(), SUMOVehicle::hasDeparted(), MSDevice::myHolder, and myPendingOutput.
Referenced by MSNet::closeSimulation().
|
static |
Definition at line 309 of file MSDevice_Tripinfo.cpp.
References myTotalDepartDelay, myVehicleCount, and STEPS2TIME.
Referenced by GUINet::getAvgDepartDelay(), and printStatistics().
|
static |
Definition at line 282 of file MSDevice_Tripinfo.cpp.
References myTotalDuration, myVehicleCount, STEPS2TIME, and SUMOReal.
Referenced by GUINet::getAvgDuration(), and printStatistics().
|
static |
accessors for GUINet-Parameters
Definition at line 273 of file MSDevice_Tripinfo.cpp.
References myTotalRouteLength, myVehicleCount, and SUMOReal.
Referenced by GUINet::getAvgRouteLength(), and printStatistics().
|
static |
Definition at line 300 of file MSDevice_Tripinfo.cpp.
References myTotalTimeLoss, myVehicleCount, STEPS2TIME, and SUMOReal.
Referenced by GUINet::getAvgTimeLoss(), and printStatistics().
|
static |
Definition at line 291 of file MSDevice_Tripinfo.cpp.
References myTotalWaitingTime, myVehicleCount, STEPS2TIME, and SUMOReal.
Referenced by GUINet::getAvgWaitingTime(), and printStatistics().
|
inlineinherited |
Definition at line 215 of file MSMoveReminder.h.
References MSMoveReminder::myDescription.
Referenced by MSBaseVehicle::addStops().
|
inlineinherited |
Returns the vehicle that holds this device.
Definition at line 105 of file MSDevice.h.
References MSDevice::myHolder.
|
inlineinherited |
Returns the id.
Definition at line 65 of file Named.h.
References Named::myID.
Referenced by NIImporter_SUMO::_loadNetwork(), MSVehicleTransfer::add(), TraCIServerAPI_Lane::StoringVisitor::add(), MSDetectorControl::add(), Named::StoringVisitor::add(), RORouteDef::addAlternative(), MSLane::addApproachingLane(), MSNet::addBusStop(), MSNet::addChargingStation(), NBLoadedSUMOTLDef::addConnection(), NLHandler::addConnection(), MSNet::addContainerStop(), NIXMLConnectionsHandler::addCrossing(), RODFDetectorCon::addDetector(), RONet::addEdge(), ROJTREdge::addFollowerProbability(), MSTLLogicControl::TLSLogicVariants::addLogic(), RONet::addNode(), NIImporter_SUMO::addPhase(), GUIEdge::addRerouter(), NBEdge::addRestrictedLane(), RONet::addRouteDef(), NBDistrict::addSink(), NBDistrict::addSource(), NIXMLEdgesHandler::addSplit(), NBTrafficLightLogic::addStep(), MSRouteHandler::addStop(), MSVehicle::addStop(), NIXMLTrafficLightsHandler::addTlConnection(), NIVissimDisturbance::addToNode(), MSVehicle::addTraciBusOrContainerStop(), MSVehicle::addTraciStop(), AGActivityTripWriter::addTrip(), GUITrafficLightLogicWrapper::begin2TrackPhases(), MSContainer::MSContainerStage_Driving::beginEventOutput(), MSContainer::MSContainerStage_Waiting::beginEventOutput(), MSPerson::MSPersonStage_Driving::beginEventOutput(), MSPerson::MSPersonStage_Waiting::beginEventOutput(), NLEdgeControlBuilder::build(), NIVisumTL::build(), RODFNet::buildApproachList(), MS_E2_ZS_CollectorOverLanes::buildCollector(), NBNode::buildCrossings(), NBNode::buildCrossingsAndWalkingAreas(), NIImporter_VISUM::buildDistrictNode(), NIVissimConnection::buildEdgeConnections(), RODFNet::buildEdgeFlowMap(), GNEConnector::buildIinternalLanes(), GNETLSEditor::buildIinternalLanes(), NBEdge::buildInnerEdges(), NGEdge::buildNBEdge(), NIVissimEdge::buildNBEdge(), NBRampsComputer::buildOffRamp(), NBRampsComputer::buildOnRamp(), NBNode::buildWalkingAreas(), MSBaseVehicle::calculateArrivalParams(), MSSimpleTrafficLightLogic::changeStepAndDuration(), NBEdge::checkGeometry(), MSVehicleTransfer::checkInsertions(), ODDistrictHandler::closeDistrict(), NLHandler::closeEdge(), RORouteHandler::closeRouteDistribution(), RORouteHandler::closeVehicle(), NBTrafficLightDefinition::collectAllLinks(), NBLoadedSUMOTLDef::collectEdges(), NBTrafficLightDefinition::collectEdges(), ROJTRRouter::compute(), NBTrafficLightDefinition::compute(), NBNode::computeInternalLaneShape(), NBEdge::computeLaneShapes(), NBNode::computeLogic(), NBOwnTLDef::computeLogicAndConts(), NBNode::computeNodeShape(), RODFNet::computeRoutesFor(), NBTrafficLightLogicCont::computeSingleLogic(), NBTurningDirectionsComputer::computeTurnDirectionsForNode(), NGNet::connect(), MSAbstractLaneChangeModel::continueLaneChangeManeuver(), NLDetectorBuilder::convUncontE2PosLength(), GUINet::createTLWrapper(), NIVissimDistrictConnection::dict_BuildDistricts(), MSContainer::MSContainerStage_Driving::endEventOutput(), MSContainer::MSContainerStage_Waiting::endEventOutput(), MSPerson::MSPersonStage_Driving::endEventOutput(), MSPerson::MSPersonStage_Waiting::endEventOutput(), MSE3Collector::enter(), MSCalibrator::execute(), Command_SaveTLSState::execute(), Command_SaveTLSSwitchStates::execute(), Command_SaveTLSSwitches::execute(), MSVTypeProbe::execute(), MSPModel_Striping::MovePedestrians::execute(), MSTrafficLightLogic::SwitchCommand::execute(), MSVehicle::executeMove(), MSLane::executeMovements(), NBNodeCont::extract(), NBTrafficLightLogicCont::extract(), NBEdgeCont::extract(), NBRampsComputer::fulfillsRampConstraints(), RODFDetectorCon::getAggFlowFor(), RODFDetectorCon::getAnyDetectorForEdge(), MSNet::getBusStopID(), MSNet::getChargingStationID(), NBEdge::getConnection(), MSNet::getContainerStopID(), NBEdge::getCrossingAngle(), GNEEdge::getDest(), RODFNet::getDetectorEdge(), MSMeanData::getEdgeID(), PedestrianEdge< E, L, N >::getEffort(), NBEdge::getFirstNonPedestrianLane(), MS_E2_ZS_CollectorOverLanes::getLanePredeccessorLanes(), MSTLLogicControl::TLSLogicVariants::getLogicInstantiatingOff(), NIImporter_VISUM::getNamedEdgeContinuating(), MSPerson::getNextEdge(), MSPModel_Striping::getNextLane(), GUIInstantInductLoop::MyWrapper::getParameterWindow(), GUI_E2_ZS_Collector::MyWrapper::getParameterWindow(), GUIVehicle::getParameterWindow(), GUIInductLoop::MyWrapper::getParameterWindow(), GUITrafficLightLogicWrapper::getPopUpMenu(), NLTriggerBuilder::getPosition(), NLDetectorBuilder::getPositionChecking(), NBNode::getPossiblySplittedIncoming(), NBNode::getPossiblySplittedOutgoing(), NIImporter_VISUM::getReversedContinuating(), GNEEdge::getSource(), MSVehicleControl::getWaitingVehicle(), MSLink::getZipperSpeed(), NBNode::guessCrossings(), RODFDetectorCon::guessEmptyFlows(), NBEdgeCont::guessSidewalks(), NBNodeCont::guessTLs(), GUITLLogicPhasesTrackerWindow::GUITLLogicPhasesTrackerWindow(), MSLane::handleCollision(), NBEdgeCont::ignoreFilterMatch(), MSRailSignal::init(), MSActuatedTrafficLightLogic::init(), MSTrafficLightLogic::init(), PedestrianEdge< E, L, N >::initPedestrianNetwork(), NIImporter_SUMO::initTrafficLightLogic(), NIXMLTrafficLightsHandler::initTrafficLightLogic(), NBDistrictCont::insert(), NBNodeCont::insert(), NBTrafficLightLogicCont::insert(), NBEdgeCont::insert(), MSEdge::insertVehicle(), GNEJunction::invalidateTLS(), NBNode::invalidateTLS(), MSTLLogicControl::isActive(), RODFNet::isDestination(), RODFNet::isFalseSource(), RODFNet::isSource(), NBNodeCont::joinJunctions(), NBEdgeCont::joinSameNodeConnectingEdges(), MSE3Collector::leave(), MSDevice_BTreceiver::BTreceiverUpdate::leaveRange(), NIImporter_OpenDrive::loadNetwork(), ODDistrictCont::makeDistricts(), MSPModel_Striping::moveInDirection(), MSPModel_Striping::moveInDirectionOnLane(), NBRampsComputer::moveRampRight(), MSPModel_Striping::PState::moveToNextLane(), MSCalibrator::MSCalibrator(), MSChargingStation::MSChargingStation(), MSDevice_Battery::MSDevice_Battery(), NBLoadedTLDef::myCompute(), NIXMLEdgesHandler::myEndElement(), NIImporter_SUMO::myEndElement(), NIXMLConnectionsHandler::myStartElement(), MSLaneSpeedTrigger::myStartElement(), MSTriggeredRerouter::myStartElement(), NBConnection::NBConnection(), NBRequest::NBRequest(), MSDevice_BTsender::notifyEnter(), MSDevice_BTreceiver::notifyEnter(), MSDevice_Example::notifyEnter(), notifyEnter(), MSTriggeredRerouter::notifyEnter(), MSDevice_Container::notifyLeave(), MSDevice_Person::notifyLeave(), MSE3Collector::MSE3EntryReminder::notifyLeave(), MSDevice_Example::notifyLeave(), notifyLeave(), MSDevice_BTsender::notifyLeave(), MSDevice_BTreceiver::notifyLeave(), MSDevice_Example::notifyMove(), MSDevice_BTsender::notifyMove(), MSDevice_BTreceiver::notifyMove(), MSMeanData::MeanDataValues::notifyMove(), GUIViewTraffic::onGamingClick(), RORouteHandler::openRoute(), Named::ComparatorIdLess::operator()(), NBTurningDirectionsComputer::combination_by_angle_sorter::operator()(), RODFNet::idComp::operator()(), NBNetBuilder::by_id_sorter::operator()(), NBOwnTLDef::edge_by_incoming_priority_sorter::operator()(), NBContHelper::same_connection_edge_sorter::operator()(), NBContHelper::edge_by_angle_to_nodeShapeCentroid_sorter::operator()(), MSEdge::by_id_sorter::operator()(), NBNode::nodes_by_id_sorter::operator()(), NIImporter_VISUM::parse_EdgePolys(), NIImporter_VISUM::parse_Lanes(), NIImporter_VISUM::parse_LanesConnections(), NIImporter_VISUM::parse_Turns(), NIImporter_VISUM::parse_TurnsToSignalGroups(), NIXMLConnectionsHandler::parseDeprecatedLaneDefinition(), NIXMLConnectionsHandler::parseLaneBound(), MSRouteHandler::parseWalkPositions(), NBLoadedSUMOTLDef::patchIfCrossingsAdded(), MSLCM_JE2013::patchSpeed(), NBLoadedTLDef::SignalGroup::patchTYellow(), MSRightOfWayJunction::postloadInit(), AGStreet::print(), TraCIServerAPI_InductionLoop::processGet(), TraCIServerAPI_ArealDetector::processGet(), TraCIServerAPI_TLS::processGet(), TraCIServerAPI_Vehicle::processGet(), TraCIServerAPI_Person::processGet(), TraCIServerAPI_Lane::processGet(), TraCIServerAPI_Vehicle::processSet(), NIXMLNodesHandler::processTrafficLightDefinitions(), NWWriter_SUMO::prohibitionConnection(), MSPModel_Striping::PState::PState(), NBEdgeCont::recheckPostProcessConnections(), NBLoadedTLDef::SignalGroup::remapIncoming(), NBLoadedTLDef::SignalGroup::remapOutgoing(), NBLoadedSUMOTLDef::removeConnection(), NBNodeCont::removeIsolatedRoads(), MSCalibrator::removePending(), NBNode::removeSelfLoops(), NBEdgeCont::removeUnwishedEdges(), NBNodeCont::removeUnwishedNodes(), NBNodeCont::rename(), NBEdgeCont::rename(), GNENet::renameEdge(), GNENet::renameJunction(), RORouteDef::repairCurrentRoute(), NBConnection::replaceFrom(), MSBaseVehicle::replaceRouteEdges(), NBConnection::replaceTo(), NIImporter_DlrNavteq::TrafficlightsHandler::report(), NIXMLTrafficLightsHandler::retrieveLaneIndex(), RODFNet::revalidateFlows(), RONet::saveAndRemoveRoutesUntil(), MSBaseVehicle::saveState(), MSDevice_Battery::setActualBatteryCapacity(), MSDevice_Battery::setAirDragCoefficient(), NBNodeCont::setAsTLControlled(), MSChargingStation::setChrgPower(), MSDevice_Battery::setConstantPowerIntake(), NBEdge::setControllingTLInformation(), MSChargingStation::setEfficency(), MSDevice_Battery::setFrontSurfaceArea(), MSDevice_Battery::setInternalMomentOfInertia(), GNEJunction::setLogicValid(), MSDevice_Battery::setMass(), MSDevice_Battery::setMaximumBatteryCapacity(), NIXMLEdgesHandler::setNodes(), MSDevice_Battery::setPowerMax(), MSDevice_Battery::setPropulsionEfficiency(), MSDevice_Battery::setRadialDragCoefficient(), MSDevice_Battery::setRecuperationEfficiency(), MSLink::setRequestInformation(), MSDevice_Battery::setRollDragCoefficient(), MSTLLogicControl::TLSLogicVariants::setStateInstantiatingOnline(), NBOwnTLDef::setTLControllingInformation(), NBLoadedSUMOTLDef::setTLControllingInformation(), NBTrafficLightLogicCont::setTLControllingInformation(), NBLoadedTLDef::setTLControllingInformation(), NBEdgeCont::splitAt(), MSLane::succLinkSec(), GUITrafficLightLogicWrapper::switchTLSLogic(), GNETLSEditor::updateDescription(), MSDevice_BTreceiver::BTreceiverUpdate::updateVisibility(), TraCIServerAPI_Vehicle::vtdMap(), TraCIServerAPI_Vehicle::vtdMap_matchingRoutePosition(), MSPModel_Striping::PState::walk(), MSLCM_JE2013::wantsChange(), MSBatteryExport::write(), MSEmissionExport::write(), MSFCDExport::write(), MSInstantInductLoop::write(), NBSign::writeAsPOI(), NWWriter_SUMO::writeConnection(), NWWriter_SUMO::writeDistrict(), MSFullExport::writeEdge(), MSXMLRawOut::writeEdge(), NWWriter_SUMO::writeEdge(), MSMeanData::writeEdge(), NWWriter_XML::writeEdgesAndConnections(), RODFDetector::writeEmitterDefinition(), RODFDetectorCon::writeEmitterPOIs(), RODFDetectorCon::writeEmitters(), RODFDetectorCon::writeEndRerouterDetectors(), NWWriter_SUMO::writeInternalConnections(), writeInterval(), NWWriter_SUMO::writeJunction(), MSQueueExport::writeLane(), MSFullExport::writeLane(), NWWriter_DlrNavteq::writeLinksUnsplitted(), NWWriter_OpenDrive::writeNetwork(), NWWriter_XML::writeNodes(), NWWriter_DlrNavteq::writeNodesUnsplitted(), NWWriter_SUMO::writeRoundabout(), RODFDetectorCon::writeSpeedTrigger(), NWWriter_DlrNavteq::writeTrafficSignals(), MSInductLoop::writeTypedXMLOutput(), RODFDetectorCon::writeValidationDetectors(), MSFullExport::writeVehicles(), PointOfInterest::writeXML(), SUMO::Polygon::writeXML(), MSRouteProbe::writeXMLOutput(), and MSE2Collector::writeXMLOutput().
|
inlinestaticinherited |
|
inlineinherited |
Returns the lane the reminder works on.
Definition at line 89 of file MSMoveReminder.h.
References MSMoveReminder::myLane.
Referenced by computeLengthAndDuration(), MSE2Collector::detectorUpdate(), GUIInstantInductLoop::MyWrapper::getParameterWindow(), GUI_E2_ZS_Collector::MyWrapper::getParameterWindow(), GUIInductLoop::MyWrapper::getParameterWindow(), TraCIServerAPI_InductionLoop::getPosition(), TraCIServerAPI_InductionLoop::getTree(), GUIInstantInductLoop::MyWrapper::MyWrapper(), GUI_E2_ZS_Collector::MyWrapper::MyWrapper(), GUIInductLoop::MyWrapper::MyWrapper(), MSMeanData_Amitran::MSLaneMeanDataValues::notifyEnter(), notifyEnter(), MSMeanData_Net::MSLaneMeanDataValues::notifyEnter(), MSMeanData_Net::MSLaneMeanDataValues::notifyLeave(), notifyLeave(), MSMeanData::MeanDataValues::notifyMove(), TraCIServerAPI_ArealDetector::processGet(), TraCIServerAPI_InductionLoop::processGet(), and MSMeanData::writeEdge().
|
staticprotectedinherited |
Adds common command options that allow to assign devices to vehicles.
[in] | deviceName | The name of the device type |
[in] | optionsTopic | The options topic into which the options shall be added |
!! describe
!! describe
!! describe
Definition at line 88 of file MSDevice.cpp.
References OptionsCont::addDescription(), OptionsCont::addSynonyme(), and OptionsCont::doRegister().
Referenced by MSDevice::generateOutput(), MSDevice_Example::insertOptions(), MSDevice_BTreceiver::insertOptions(), MSDevice_BTsender::insertOptions(), MSDevice_Battery::insertOptions(), MSDevice_Emissions::insertOptions(), and MSDevice_Routing::insertOptions().
|
staticinherited |
Inserts options for building devices.
Definition at line 64 of file MSDevice.cpp.
References MSDevice_Example::insertOptions(), MSDevice_BTreceiver::insertOptions(), MSDevice_BTsender::insertOptions(), MSDevice_Battery::insertOptions(), MSDevice_Emissions::insertOptions(), and MSDevice_Routing::insertOptions().
Referenced by MSFrame::fillOptions().
|
virtual |
Saves departure info on insertion.
[in] | veh | The entering vehicle. |
[in] | reason | how the vehicle enters the lane |
Reimplemented from MSMoveReminder.
Definition at line 121 of file MSDevice_Tripinfo.cpp.
References Named::getID(), MSMoveReminder::getLane(), SUMOVehicle::getPositionOnLane(), SUMOVehicle::getSpeed(), MSGlobals::gUseMesoSim, myDepartLane, myDepartPos, myDepartSpeed, and MSMoveReminder::NOTIFICATION_DEPARTED.
|
virtual |
Saves arrival info.
[in] | veh | The leaving vehicle. |
[in] | lastPos | Position on the lane when leaving. |
[in] | isArrival | whether the vehicle arrived at its destination |
[in] | isLaneChange | whether the vehicle changed from the lane |
Reimplemented from MSMoveReminder.
Definition at line 134 of file MSDevice_Tripinfo.cpp.
References SUMOVehicle::getArrivalPos(), MSNet::getCurrentTimeStep(), Named::getID(), MSNet::getInstance(), MSMoveReminder::getLane(), SUMOVehicle::getPositionOnLane(), SUMOVehicle::getSpeed(), MSGlobals::gUseMesoSim, myArrivalLane, myArrivalPos, myArrivalSpeed, myArrivalTime, MSDevice::myHolder, MSMoveReminder::NOTIFICATION_ARRIVED, and MSMoveReminder::NOTIFICATION_VAPORIZED.
|
virtual |
Checks for waiting steps when the vehicle moves.
[in] | veh | Vehicle that asks this reminder. |
[in] | oldPos | Position before move. |
[in] | newPos | Position after move with newSpeed. |
[in] | newSpeed | Moving speed. |
Reimplemented from MSMoveReminder.
Definition at line 101 of file MSDevice_Tripinfo.cpp.
References SUMOVehicle::getEdge(), SUMOVehicle::getMaxSpeed(), MSEdge::getVehicleMaxSpeed(), MIN2(), myTimeLoss, myWaitingSteps, SUMO_const_haltingSpeed, SUMOReal, TIME2STEPS, and TS.
|
inlinevirtualinherited |
Internal notification about the vehicle moves.
Indicator if the reminders is still active for the passed vehicle/parameters. If false, the vehicle will erase this reminder from it's reminder-container.
[in] | veh | Vehicle that asks this reminder. |
[in] | timeOnLane | time the vehicle spent on the lane. |
[in] | speed | Moving speed. |
Reimplemented in MSMeanData::MeanDataValueTracker, MSMeanData_Net::MSLaneMeanDataValues, MSMeanData_Harmonoise::MSLaneMeanDataValues, MSMeanData_Amitran::MSLaneMeanDataValues, and MSMeanData_Emissions::MSLaneMeanDataValues.
Definition at line 203 of file MSMoveReminder.h.
References UNUSED_PARAMETER.
Referenced by MSMoveReminder::MSMoveReminder(), and MSMeanData::MeanDataValues::notifyMove().
|
private |
Invalidated assignment operator.
|
static |
get statistics for printing to stdout
Definition at line 258 of file MSDevice_Tripinfo.cpp.
References getAvgDepartDelay(), getAvgDuration(), getAvgRouteLength(), getAvgTimeLoss(), getAvgWaitingTime(), OUTPUT_ACCURACY, and SUMOReal.
Referenced by MSNet::closeSimulation().
|
inlineinherited |
Definition at line 211 of file MSMoveReminder.h.
References MSMoveReminder::myDescription.
Referenced by MSMeanData::init(), and MSCalibrator::MSCalibrator().
|
inlineinherited |
resets the id
[in] | newID | The new id of this object |
Definition at line 73 of file Named.h.
References Named::myID.
Referenced by NBNodeCont::rename(), and NBEdgeCont::rename().
void MSDevice_Tripinfo::updateStatistics | ( | ) | const |
update tripinfo statistics
Definition at line 243 of file MSDevice_Tripinfo.cpp.
References computeLengthAndDuration(), DELTA_T, SUMOVehicle::getDepartDelay(), MSDevice::myHolder, myTimeLoss, myTotalDepartDelay, myTotalDuration, myTotalRouteLength, myTotalTimeLoss, myTotalWaitingTime, myVehicleCount, myWaitingSteps, and SUMOReal.
Referenced by generateOutput().
|
private |
The lane the vehicle arrived at.
Definition at line 172 of file MSDevice_Tripinfo.h.
Referenced by generateOutput(), and notifyLeave().
|
private |
The position on the lane the vehicle arrived at.
Definition at line 175 of file MSDevice_Tripinfo.h.
Referenced by computeLengthAndDuration(), generateOutput(), and notifyLeave().
|
private |
The speed when arriving.
Definition at line 178 of file MSDevice_Tripinfo.h.
Referenced by generateOutput(), and notifyLeave().
|
private |
The vehicle's arrival time.
Definition at line 169 of file MSDevice_Tripinfo.h.
Referenced by computeLengthAndDuration(), generateOutput(), and notifyLeave().
|
private |
The lane the vehicle departed at.
Definition at line 157 of file MSDevice_Tripinfo.h.
Referenced by generateOutput(), and notifyEnter().
|
private |
The position on the lane the vehicle departed at.
Definition at line 160 of file MSDevice_Tripinfo.h.
Referenced by computeLengthAndDuration(), generateOutput(), and notifyEnter().
|
private |
The speed on departure.
Definition at line 163 of file MSDevice_Tripinfo.h.
Referenced by generateOutput(), and notifyEnter().
|
protectedinherited |
a description of this moveReminder
Definition at line 229 of file MSMoveReminder.h.
Referenced by MSMoveReminder::getDescription(), and MSMoveReminder::setDescription().
|
protectedinherited |
The vehicle that stores the device.
Definition at line 153 of file MSDevice.h.
Referenced by MSDevice_Vehroutes::addRoute(), computeLengthAndDuration(), MSDevice_Vehroutes::generateOutput(), generateOutput(), generateOutputForUnfinished(), MSDevice::getHolder(), MSDevice_Vehroutes::notifyEnter(), notifyLeave(), MSDevice_Routing::preInsertionReroute(), MSDevice_Routing::reroute(), updateStatistics(), MSDevice_Vehroutes::writeXMLRoute(), and MSDevice_Vehroutes::~MSDevice_Vehroutes().
|
protectedinherited |
The name of the object.
Definition at line 133 of file Named.h.
Referenced by GUI_E2_ZS_CollectorOverLanes::buildCollector(), RODFDetector::buildDestinationDistribution(), NGEdge::buildNBEdge(), NGNode::buildNBNode(), NBNode::computeNodeShape(), MSCalibrator::execute(), Named::getID(), NBEdge::getLaneID(), NBEdge::getLaneIDInsecure(), ROEdge::getStoredEffort(), ROEdge::getTravelTime(), MSActuatedTrafficLightLogic::init(), MSCalibrator::init(), NBEdge::init(), MSCalibrator::myStartElement(), MSMeanData::openInterval(), RORouteDef::preComputeCurrentRoute(), NBEdge::reinitNodes(), MSRoute::release(), RORouteDef::repairCurrentRoute(), Named::setID(), NBEdge::splitGeometry(), RODFDetector::writeEmitterDefinition(), MSXMLRawOut::writeLane(), NBNode::writeLogic(), RODFDetector::writeSingleSpeedTrigger(), MSCalibrator::writeXMLOutput(), and MSE3Collector::writeXMLOutput().
|
protectedinherited |
Lane on which the reminder works.
Definition at line 227 of file MSMoveReminder.h.
Referenced by MSE2Collector::detectorUpdate(), MSMoveReminder::getLane(), MSE2Collector::MSE2Collector(), MSMoveReminder::MSMoveReminder(), MSE2Collector::by_vehicle_position_sorter::operator()(), and MSMeanData::MeanDataValueTracker::reset().
|
staticprivate |
Definition at line 186 of file MSDevice_Tripinfo.h.
Referenced by buildVehicleDevices(), generateOutput(), generateOutputForUnfinished(), and ~MSDevice_Tripinfo().
|
private |
The time loss when compared to the desired and allowed speed.
Definition at line 181 of file MSDevice_Tripinfo.h.
Referenced by generateOutput(), notifyMove(), and updateStatistics().
|
staticprivate |
Definition at line 194 of file MSDevice_Tripinfo.h.
Referenced by getAvgDepartDelay(), and updateStatistics().
|
staticprivate |
Definition at line 191 of file MSDevice_Tripinfo.h.
Referenced by getAvgDuration(), and updateStatistics().
|
staticprivate |
Definition at line 190 of file MSDevice_Tripinfo.h.
Referenced by getAvgRouteLength(), and updateStatistics().
|
staticprivate |
Definition at line 193 of file MSDevice_Tripinfo.h.
Referenced by getAvgTimeLoss(), and updateStatistics().
|
staticprivate |
Definition at line 192 of file MSDevice_Tripinfo.h.
Referenced by getAvgWaitingTime(), and updateStatistics().
|
staticprivate |
global tripinfo statistics
Definition at line 189 of file MSDevice_Tripinfo.h.
Referenced by getAvgDepartDelay(), getAvgDuration(), getAvgRouteLength(), getAvgTimeLoss(), getAvgWaitingTime(), and updateStatistics().
|
private |
The overall number of waiting steps.
Definition at line 166 of file MSDevice_Tripinfo.h.
Referenced by generateOutput(), notifyMove(), and updateStatistics().