SUMO - Simulation of Urban MObility
GUIInductLoop Class Reference

The gui-version of the MSInductLoop. More...

#include <GUIInductLoop.h>

Inheritance diagram for GUIInductLoop:
Inheritance graph
Collaboration diagram for GUIInductLoop:
Collaboration graph

Data Structures

class  MyWrapper
 A MSInductLoop-visualiser. More...
 

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...
 
virtual GUIDetectorWrapperbuildDetectorGUIRepresentation ()
 Returns this detector's visualisation-wrapper. More...
 
std::vector< VehicleDatacollectVehiclesOnDet (SUMOTime t, bool leaveTime=false) const
 Returns vehicle data for vehicles that have been on the detector starting at the given time. More...
 
const std::string & getDescription () const
 
const std::string & getID () const
 Returns the id. More...
 
const MSLanegetLane () const
 Returns the lane the reminder works on. More...
 
SUMOReal getPosition () const
 Returns the position of the detector on the lane. More...
 
 GUIInductLoop (const std::string &id, MSLane *const lane, SUMOReal position, const std::string &vTypes)
 Constructor. More...
 
virtual void notifyMoveInternal (const SUMOVehicle &veh, const SUMOReal frontOnLane, const SUMOReal timeOnLane, const SUMOReal meanSpeedFrontOnLane, const SUMOReal meanSpeedVehicleOnLane, const SUMOReal travelledDistanceFrontOnLane, const SUMOReal travelledDistanceVehicleOnLane)
 Internal notification about the vehicle moves. More...
 
void reset ()
 Resets all generated values to allow computation of next interval. More...
 
void setDescription (const std::string &description)
 
void setID (const std::string &newID)
 resets the id More...
 
 ~GUIInductLoop ()
 Destructor. More...
 
Methods inherited from MSMoveReminder
bool notifyEnter (SUMOVehicle &veh, Notification reason)
 Checks whether the reminder is activated by a vehicle entering the lane. More...
 
bool notifyMove (SUMOVehicle &veh, SUMOReal oldPos, SUMOReal newPos, SUMOReal newSpeed)
 Checks whether the vehicle shall be counted and/or shall still touch this MSMoveReminder. More...
 
bool notifyLeave (SUMOVehicle &veh, SUMOReal lastPos, MSMoveReminder::Notification reason)
 Dismisses the vehicle if it is on the detector due to a lane change. More...
 
Methods returning current values
SUMOReal getCurrentSpeed () const
 Returns the speed of the vehicle on the detector. More...
 
SUMOReal getCurrentLength () const
 Returns the length of the vehicle on the detector. More...
 
SUMOReal getCurrentOccupancy () const
 Returns the current occupancy. More...
 
int getCurrentPassedNumber () const
 Returns the number of vehicles that have passed the detector. More...
 
std::vector< std::string > getCurrentVehicleIDs () const
 Returns the ids of vehicles that have passed the detector. More...
 
SUMOReal getTimestepsSinceLastDetection () const
 Returns the time since the last vehicle left the detector. More...
 
Methods inherited from MSDetectorFileOutput.
void writeXMLOutput (OutputDevice &dev, SUMOTime startTime, SUMOTime stopTime)
 Writes collected values into the given stream. More...
 
void writeXMLDetectorProlog (OutputDevice &dev) const
 Opens the XML-output using "detector" as root element. More...
 
Interface methods, to be derived by subclasses
void updateDetector (SUMOVehicle &veh, SUMOReal entryPos, SUMOReal leavePos, SUMOTime entryTime, SUMOTime currentTime, SUMOTime leaveTime, bool cleanUp)
 

Static Public Member Functions

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...
 

Data Fields

MFXMutex myLock
 Mutex preventing parallel read/write access to internal MSInductLoop state. More...
 

Protected Types

typedef std::deque< VehicleDataVehicleDataCont
 Type of myVehicleDataCont. More...
 
typedef std::map< SUMOVehicle *, SUMORealVehicleMap
 Type of myVehiclesOnDet. More...
 

Protected Member Functions

void removeFromVehicleUpdateValues (SUMOVehicle &veh)
 
Methods that add and remove vehicles from internal container
void enterDetectorByMove (SUMOVehicle &veh, SUMOReal entryTimestep)
 Introduces a vehicle to the detector's map myVehiclesOnDet. More...
 
void leaveDetectorByMove (SUMOVehicle &veh, SUMOReal leaveTimestep)
 Processes a vehicle that leaves the detector. More...
 
void leaveDetectorByLaneChange (SUMOVehicle &veh, SUMOReal lastPos)
 Removes a vehicle from the detector's map myVehiclesOnDet. More...
 

Static Protected Member Functions

Function for summing up values
static SUMOReal speedSum (SUMOReal sumSoFar, const MSInductLoop::VehicleData &data)
 Adds up VehicleData::speedM. More...
 
static SUMOReal lengthSum (SUMOReal sumSoFar, const MSInductLoop::VehicleData &data)
 Adds up VehicleData::lengthM. More...
 

Protected Attributes

std::string myDescription
 a description of this moveReminder More...
 
int myEnteredVehicleNumber
 The number of entered vehicles. More...
 
std::string myID
 The name of the object. More...
 
MSLane *const myLane
 Lane on which the reminder works. More...
 
SUMOReal myLastLeaveTime
 Leave-time of the last vehicle detected [s]. More...
 
SUMOReal myLastOccupancy
 Occupancy by the last vehicle detected. More...
 
VehicleDataCont myLastVehicleDataCont
 Data of vehicles that have completely passed the detector in the last time interval. More...
 
const SUMOReal myPosition
 Detector's position on lane [m]. More...
 
VehicleDataCont myVehicleDataCont
 Data of vehicles that have completely passed the detector. More...
 
VehicleMap myVehiclesOnDet
 Data for vehicles that have entered the detector (vehicle -> enter time) More...
 

Virtual methods to implement by derived classes

virtual void detectorUpdate (const SUMOTime step)
 Updates the detector (computes values) More...
 
bool vehicleApplies (const SUMOVehicle &veh) const
 Checks whether the detector measures vehicles of the given type. More...
 
bool isTyped () const
 Checks whether the detector is type specific. More...
 
std::set< std::string > myVehicleTypes
 The vehicle types to look for (empty means all) More...
 

Detailed Description

The gui-version of the MSInductLoop.

Allows the building of a wrapper (also declared herein) which draws the detector on the gl-canvas. Uses a mutex to avoid parallel read/write operations. The mutex is only set within methods that change MSInductLoop-internal state and within "collectVehiclesOnDet". All other reading operations should be performed via the simulation loop only.

Definition at line 55 of file GUIInductLoop.h.

Member Typedef Documentation

§ VehicleDataCont

typedef std::deque< VehicleData > MSInductLoop::VehicleDataCont
protectedinherited

Type of myVehicleDataCont.

Definition at line 355 of file MSInductLoop.h.

§ VehicleMap

typedef std::map< SUMOVehicle*, SUMOReal > MSInductLoop::VehicleMap
protectedinherited

Type of myVehiclesOnDet.

Definition at line 365 of file MSInductLoop.h.

Member Enumeration Documentation

§ Notification

Definition of a vehicle state.

Enumerator
NOTIFICATION_DEPARTED 

The vehicle has departed (was inserted into the network)

NOTIFICATION_JUNCTION 

The vehicle arrived at a junction.

NOTIFICATION_SEGMENT 

The vehicle changes the segment (meso only)

NOTIFICATION_LANE_CHANGE 

The vehicle changes lanes (micro only) XXX: What if a vehicle changes lanes and passes a junction simultaneously?

NOTIFICATION_TELEPORT 

The vehicle is being teleported.

NOTIFICATION_PARKING 

The vehicle starts or ends parking.

NOTIFICATION_ARRIVED 

The vehicle arrived at its destination (is deleted)

NOTIFICATION_VAPORIZED 

The vehicle got vaporized.

NOTIFICATION_TELEPORT_ARRIVED 

The vehicle was teleported out of the net.

Definition at line 95 of file MSMoveReminder.h.

Constructor & Destructor Documentation

§ GUIInductLoop()

GUIInductLoop::GUIInductLoop ( const std::string &  id,
MSLane *const  lane,
SUMOReal  position,
const std::string &  vTypes 
)

Constructor.

Parameters
[in]idUnique id
[in]laneLane where detector woks on
[in]positionPosition of the detector within the lane
[in]splitByTypeWhether additional information split by vehicle classes shall be generated

Definition at line 55 of file GUIInductLoop.cpp.

§ ~GUIInductLoop()

GUIInductLoop::~GUIInductLoop ( )

Destructor.

Definition at line 60 of file GUIInductLoop.cpp.

Member Function Documentation

§ addTo()

void Named::addTo ( const StoringVisitor cont) const
inlineinherited

Adds this object to the given container.

Parameters

Definition at line 129 of file Named.h.

References Named::StoringVisitor::add().

§ buildDetectorGUIRepresentation()

GUIDetectorWrapper * GUIInductLoop::buildDetectorGUIRepresentation ( )
virtual

Returns this detector's visualisation-wrapper.

Returns
The wrapper representing the detector

Reimplemented from MSDetectorFileOutput.

Definition at line 64 of file GUIInductLoop.cpp.

References MSInductLoop::myPosition.

§ collectVehiclesOnDet()

std::vector< MSInductLoop::VehicleData > GUIInductLoop::collectVehiclesOnDet ( SUMOTime  t,
bool  leaveTime = false 
) const
virtual

Returns vehicle data for vehicles that have been on the detector starting at the given time.

This method uses a mutex to prevent parallel read/write access to the vehicle buffer

Parameters
[in]tThe time from which vehicles shall be counted
[in]leaveTimeWhether entryTime or leaveTime shall be compared against t (the latter gives a more complete picture but may include vehicles in multiple steps even if they did not stay on the detector)
Returns
The list of vehicles
See also
MSInductLoop::collectVehiclesOnDet()

Reimplemented from MSInductLoop.

Definition at line 96 of file GUIInductLoop.cpp.

References MSInductLoop::collectVehiclesOnDet(), and myLock.

§ detectorUpdate()

virtual void MSDetectorFileOutput::detectorUpdate ( const SUMOTime  step)
inlinevirtualinherited

Updates the detector (computes values)

Parameters
[in]stepThe current time step

Reimplemented in MSMeanData, MSE3Collector, MSE2Collector, and MSMeanData_Harmonoise.

Definition at line 126 of file MSDetectorFileOutput.h.

References UNUSED_PARAMETER.

§ enterDetectorByMove()

void GUIInductLoop::enterDetectorByMove ( SUMOVehicle veh,
SUMOReal  entryTimestep 
)
protectedvirtual

Introduces a vehicle to the detector's map myVehiclesOnDet.

Locks the internal mutex before calling MSInductLoop::enterDetectorByMove()

See also
MSInductLoop::enterDetectorByMove()
Parameters
vehThe entering vehicle.
entryTimestepTimestep (not necessary integer) of entrance.
See also
MSInductLoop::enterDetectorByMove()

Reimplemented from MSInductLoop.

Definition at line 77 of file GUIInductLoop.cpp.

References MSInductLoop::enterDetectorByMove(), and myLock.

§ getCurrentLength()

SUMOReal MSInductLoop::getCurrentLength ( ) const
inherited

Returns the length of the vehicle on the detector.

If no vehicle is on the detector, -1 is returned, otherwise this vehicle's length.

Returns
The length [m] of the vehicle if one is on the detector, -1 otherwise

Definition at line 167 of file MSInductLoop.cpp.

References MSInductLoop::collectVehiclesOnDet(), DELTA_T, MSNet::getInstance(), MSInductLoop::lengthSum(), and SUMOReal.

Referenced by GUIInductLoop::MyWrapper::getParameterWindow(), MSInductLoop::getPosition(), and TraCIServerAPI_InductionLoop::processGet().

§ getCurrentOccupancy()

SUMOReal MSInductLoop::getCurrentOccupancy ( ) const
inherited

Returns the current occupancy.

If a vehicle is on the detector, 1 is returned. If a vehicle has passed the detector in this timestep, its occupancy value is returned. If no vehicle has passed, 0 is returned.

Returns
This detector's current occupancy
Todo:
recheck (especially if more than one vehicle has passed)

Definition at line 176 of file MSInductLoop.cpp.

References MSInductLoop::collectVehiclesOnDet(), DELTA_T, MSNet::getCurrentTimeStep(), MSNet::getInstance(), HAS_NOT_LEFT_DETECTOR, MAX2(), MIN2(), STEPS2TIME, SUMOReal, and TS.

Referenced by GUIInductLoop::MyWrapper::getParameterWindow(), MSInductLoop::getPosition(), and TraCIServerAPI_InductionLoop::processGet().

§ getCurrentPassedNumber()

int MSInductLoop::getCurrentPassedNumber ( ) const
inherited

Returns the number of vehicles that have passed the detector.

If a vehicle is on the detector, 1 is returned. If a vehicle has passed the detector in this timestep, 1 is returned. If no vehicle has passed, 0 is returned.

Returns
The number of vehicles that have passed the detector
Todo:
recheck (especially if more than one vehicle has passed)

Definition at line 194 of file MSInductLoop.cpp.

References MSInductLoop::collectVehiclesOnDet(), DELTA_T, and MSNet::getInstance().

Referenced by GUIInductLoop::MyWrapper::getParameterWindow(), MSInductLoop::getPosition(), and TraCIServerAPI_InductionLoop::processGet().

§ getCurrentSpeed()

SUMOReal MSInductLoop::getCurrentSpeed ( ) const
inherited

Returns the speed of the vehicle on the detector.

If no vehicle is on the detector, -1 is returned, otherwise this vehicle's current speed.

Returns
The speed [m/s] of the vehicle if one is on the detector, -1 otherwise

Definition at line 158 of file MSInductLoop.cpp.

References MSInductLoop::collectVehiclesOnDet(), DELTA_T, MSNet::getInstance(), MSInductLoop::speedSum(), and SUMOReal.

Referenced by GUIInductLoop::MyWrapper::getParameterWindow(), MSInductLoop::getPosition(), and TraCIServerAPI_InductionLoop::processGet().

§ getCurrentVehicleIDs()

std::vector< std::string > MSInductLoop::getCurrentVehicleIDs ( ) const
inherited

Returns the ids of vehicles that have passed the detector.

Returns
The ids of vehicles that have passed the detector
Todo:
recheck (especially if more than one vehicle has passed)

Definition at line 201 of file MSInductLoop.cpp.

References MSInductLoop::collectVehiclesOnDet(), DELTA_T, MSNet::getInstance(), and SUMOReal.

Referenced by MSInductLoop::getPosition(), and TraCIServerAPI_InductionLoop::processGet().

§ getDescription()

const std::string& MSMoveReminder::getDescription ( ) const
inlineinherited

§ getID()

const std::string& Named::getID ( ) const
inlineinherited

Returns the id.

Returns
The stored id

Definition at line 66 of file Named.h.

References Named::myID.

Referenced by NIImporter_SUMO::_loadNetwork(), MSVehicle::adaptToLeader(), MSVehicle::adaptToLeaders(), PCPolyContainer::add(), MSVehicleTransfer::add(), TraCIServerAPI_Lane::StoringVisitor::add(), MSDetectorControl::add(), Named::StoringVisitor::add(), ShapeContainer::add(), IntermodalRouter< E, L, N, V >::addAccess(), NLTriggerBuilder::addAccess(), 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(), ROVehicle::addStop(), MSVehicle::addStop(), NBEdge::addStraightConnections(), NIXMLTrafficLightsHandler::addTlConnection(), NIVissimDisturbance::addToNode(), MSVehicle::addTraciBusOrContainerStop(), MSVehicle::addTraciStop(), AGActivityTripWriter::addTrip(), GUITrafficLightLogicWrapper::begin2TrackPhases(), MSTransportable::Stage_Waiting::beginEventOutput(), MSTransportable::Stage_Driving::beginEventOutput(), NLEdgeControlBuilder::build(), NIVisumTL::build(), RODFNet::buildApproachList(), MS_E2_ZS_CollectorOverLanes::buildCollector(), MSSOTLE2Sensors::buildContinueSensior(), MSSOTLE2Sensors::buildCountSensorForLane(), MSSOTLE2Sensors::buildCountSensorForOutLane(), NBNode::buildCrossings(), NBNode::buildCrossingsAndWalkingAreas(), NIImporter_VISUM::buildDistrictNode(), NIVissimConnection::buildEdgeConnections(), RODFNet::buildEdgeFlowMap(), GNETLSEditorFrame::buildIinternalLanes(), NBEdge::buildInnerEdges(), NGEdge::buildNBEdge(), NIVissimEdge::buildNBEdge(), NBRampsComputer::buildOffRamp(), NBRampsComputer::buildOnRamp(), MELoop::buildSegmentsFor(), MSSOTLE2Sensors::buildSensorForLane(), MSSOTLE2Sensors::buildSensorForOutLane(), NBNode::buildWalkingAreas(), MSBaseVehicle::calculateArrivalParams(), MSSwarmTrafficLightLogic::calculateEtaDiff(), MSSwarmTrafficLightLogic::calculateEtaRatio(), MSSOTLPolicyBasedTrafficLightLogic::canRelease(), MSLaneChanger::changeOpposite(), MELoop::changeSegment(), MSSimpleTrafficLightLogic::changeStepAndDuration(), NBEdge::checkGeometry(), MSVehicleTransfer::checkInsertions(), MSVehicle::checkRewindLinkLanes(), MSSwarmTrafficLightLogic::choosePolicy(), ODDistrictHandler::closeDistrict(), NLHandler::closeEdge(), RORouteHandler::closeRouteDistribution(), RORouteHandler::closeVehicle(), NBTrafficLightDefinition::collectAllLinks(), NBLoadedSUMOTLDef::collectEdges(), NBTrafficLightDefinition::collectEdges(), NBLoadedSUMOTLDef::collectEdgeVectors(), NBLoadedTLDef::collectLinks(), ROJTRRouter::compute(), NBTrafficLightDefinition::compute(), NBNode::computeInternalLaneShape(), NBEdge::computeLaneShapes(), NBNode::computeLogic(), NBOwnTLDef::computeLogicAndConts(), NBNode::computeNodeShape(), NBNodeShapeComputer::computeNodeShapeDefault(), NBNodeShapeComputer::computeNodeShapeSmall(), RODFNet::computeRoutesFor(), NBTrafficLightLogicCont::computeSingleLogic(), NBNode::computeSmoothShape(), NBTurningDirectionsComputer::computeTurnDirectionsForNode(), NGNet::connect(), NLDetectorBuilder::convUncontE2PosLength(), MSSOTLWaveTrafficLightLogic::countVehicles(), MSSOTLE2Sensors::countVehicles(), GUINet::createTLWrapper(), MSDeterministicHiLevelTrafficLightLogic::decideNextPhase(), MSSOTLPolicyBasedTrafficLightLogic::decideNextPhase(), MSSwarmTrafficLightLogic::decideNextPhase(), MSDeterministicHiLevelTrafficLightLogic::decidePolicy(), MSSwarmTrafficLightLogic::decidePolicy(), NIVissimDistrictConnection::dict_BuildDistricts(), NBEdge::divideOnEdges(), NBEdge::divideSelectedLanesOnEdges(), MSTransportable::Stage_Waiting::endEventOutput(), MSTransportable::Stage_Driving::endEventOutput(), MSE3Collector::enter(), METriggeredCalibrator::execute(), 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(), TraCIServerAPI_Vehicle::findCloserLane(), NBRampsComputer::fulfillsRampConstraints(), RODFDetectorCon::getAggFlowFor(), RODFDetectorCon::getAnyDetectorForEdge(), GNEConnection::getAttribute(), MSVehicle::getBackPosition(), MSNet::getBusStopID(), MSVehicle::getCenterOnEdge(), MSDevice_Battery::getChargingStationID(), MSNet::getChargingStationID(), NBEdge::getConnection(), NBEdge::getConnectionRef(), MSNet::getContainerStopID(), NBEdge::getCrossingAngle(), RODFNet::getDetectorEdge(), MSMeanData::getEdgeID(), MSE2Collector::getEstimateQueueLength(), NBEdge::getFirstNonPedestrianLane(), MSLane::getFollower(), MSLane::getFollowerOnConsecutive(), MSLane::getFollowersOnConsecutive(), GNEEdge::getGNEJunctionDest(), GNEEdge::getGNEJunctionSource(), MSLink::getInternalLengthsAfter(), MS_E2_ZS_CollectorOverLanes::getLanePredeccessorLanes(), MSLane::getLastVehicleInformation(), MSVehicle::getLatOffset(), MSLane::getLeader(), MSLane::getLeaderOnConsecutive(), MSLane::getLeadersOnConsecutive(), MSTLLogicControl::TLSLogicVariants::getLogicInstantiatingOff(), MSDeterministicHiLevelTrafficLightLogic::getMeanSpeedForInputLanes(), MSDeterministicHiLevelTrafficLightLogic::getMeanSpeedForOutputLanes(), NIImporter_VISUM::getNamedEdgeContinuating(), MSPerson::getNextEdge(), MSPModel_Striping::getNextLane(), MSLane::getOppositeFollower(), MSLane::getOppositeLeader(), MSLane::getOppositePos(), GUIInstantInductLoop::MyWrapper::getParameterWindow(), GUIMEInductLoop::MyWrapper::getParameterWindow(), GUIVehicle::getParameterWindow(), GUI_E2_ZS_Collector::MyWrapper::getParameterWindow(), GUIInductLoop::MyWrapper::getParameterWindow(), MSLane::getPartialBehind(), MSSOTLTrafficLightLogic::getPhaseIndexWithMaxCTS(), MSSwarmTrafficLightLogic::getPheromoneForInputLanes(), MSSwarmTrafficLightLogic::getPheromoneForOutputLanes(), GUITrafficLightLogicWrapper::getPopUpMenu(), NLTriggerBuilder::getPosition(), NLDetectorBuilder::getPositionChecking(), NBNode::getPossiblySplittedIncoming(), NBNode::getPossiblySplittedOutgoing(), NIImporter_VISUM::getReversedContinuating(), MSVehicleControl::getWaitingVehicle(), MSLink::getZipperSpeed(), NBNode::guessCrossings(), RODFDetectorCon::guessEmptyFlows(), NBEdgeCont::guessSidewalks(), NBNodeCont::guessTLs(), GUITLLogicPhasesTrackerWindow::GUITLLogicPhasesTrackerWindow(), MSLane::handleCollisionBetween(), NBEdgeCont::ignoreFilterMatch(), MSDeterministicHiLevelTrafficLightLogic::init(), MSRailSignal::init(), MSActuatedTrafficLightLogic::init(), MSTrafficLightLogic::init(), MSSOTLTrafficLightLogic::init(), MSSwarmTrafficLightLogic::init(), NIImporter_SUMO::initTrafficLightLogic(), NIXMLTrafficLightsHandler::initTrafficLightLogic(), NBDistrictCont::insert(), NBNodeCont::insert(), NBTrafficLightLogicCont::insert(), NBEdgeCont::insert(), MSEdge::insertVehicle(), IntermodalNetwork< E, L, N, V >::IntermodalNetwork(), GNEJunction::invalidateTLS(), NBNode::invalidateTLS(), MSTLLogicControl::isActive(), MSPedestrianPushButton::isActiveForEdge(), MSPedestrianPushButton::isActiveOnAnySideOfTheRoad(), RODFNet::isDestination(), RODFNet::isFalseSource(), MSLane::isInsertionSuccess(), RODFNet::isSource(), MSSOTLTrafficLightLogic::isThresholdPassed(), NBNodeCont::joinJunctions(), NBEdgeCont::joinSameNodeConnectingEdges(), MSE3Collector::leave(), MSE3Collector::leaveFront(), MSDevice_BTreceiver::BTreceiverUpdate::leaveRange(), MSPedestrianPushButton::loadCrossingEdgeMap(), NIImporter_OpenDrive::loadNetwork(), MSPedestrianPushButton::loadPushButtons(), NBEdge::MainDirections::MainDirections(), ODDistrictCont::makeDistricts(), NBNodeCont::mapToNumericalIDs(), NBEdgeCont::mapToNumericalIDs(), GNEJunction::markAsModified(), MSSOTLE2Sensors::meanVehiclesSpeed(), METriggeredCalibrator::METriggeredCalibrator(), 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_BTreceiver::notifyEnter(), MSDevice_BTsender::notifyEnter(), MSDevice_Example::notifyEnter(), MSDevice_Tripinfo::notifyEnter(), MSTriggeredRerouter::notifyEnter(), MSDevice_Transportable::notifyLeave(), MSE3Collector::MSE3EntryReminder::notifyLeave(), MSDevice_Example::notifyLeave(), MSDevice_Tripinfo::notifyLeave(), MSDevice_BTreceiver::notifyLeave(), MSDevice_BTsender::notifyLeave(), MSDevice_Example::notifyMove(), MSDevice_BTreceiver::notifyMove(), MSMeanData::MeanDataValues::notifyMove(), MSDevice_BTsender::notifyMove(), MSE2Collector::notifyMove(), GUIViewTraffic::onGamingClick(), GNEViewNet::onLeftBtnPress(), 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()(), NBNode::nodes_by_id_sorter::operator()(), MSEdge::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_SL2015::patchSpeed(), MSLCM_LC2013::patchSpeed(), NBLoadedTLDef::SignalGroup::patchTYellow(), MSVehicle::planMove(), MSLane::planMovements(), MSRightOfWayJunction::postloadInit(), NBEdge::prepareEdgePriorities(), MSAbstractLaneChangeModel::primaryLaneChanged(), AGStreet::print(), TraCIServerAPI_InductionLoop::processGet(), TraCIServerAPI_TLS::processGet(), TraCIServerAPI_Vehicle::processGet(), TraCIServerAPI_Person::processGet(), TraCIServerAPI_ArealDetector::processGet(), TraCIServerAPI_Lane::processGet(), MSVehicle::processNextStop(), TraCIServerAPI_Vehicle::processSet(), NIXMLNodesHandler::processTrafficLightDefinitions(), NWWriter_SUMO::prohibitionConnection(), MSPModel_Striping::PState::PState(), NBEdgeCont::recheckPostProcessConnections(), NIImporter_OpenStreetMap::reconstructLayerElevation(), NBLoadedTLDef::SignalGroup::remapIncoming(), NBLoadedTLDef::SignalGroup::remapOutgoing(), NBLoadedSUMOTLDef::removeConnection(), NBNodeCont::removeIsolatedRoads(), MSCalibrator::removePending(), NBNode::removeSelfLoops(), NBEdgeCont::removeUnwishedEdges(), NBNodeCont::rename(), NBEdgeCont::rename(), GNENet::renameEdge(), GNENet::renameJunction(), RORouteDef::repairCurrentRoute(), NBConnection::replaceFrom(), MSBaseVehicle::replaceRouteEdges(), NBConnection::replaceTo(), NIImporter_DlrNavteq::TrafficlightsHandler::report(), MSBaseVehicle::reroute(), MSLane::resetPartialOccupation(), NBEdge::restoreRestrictedLane(), GNEEdge::retrieveConnection(), NIXMLTrafficLightsHandler::retrieveLaneIndex(), RODFNet::revalidateFlows(), RONet::saveAndRemoveRoutesUntil(), MSBaseVehicle::saveState(), MSLane::saveState(), MSDevice_Battery::setAirDragCoefficient(), NBNodeCont::setAsTLControlled(), MSChargingStation::setChargeDelay(), MSChargingStation::setChargingPower(), MSDevice_Battery::setConstantPowerIntake(), NBEdge::setControllingTLInformation(), MSChargingStation::setEfficency(), MSDevice_Battery::setFrontSurfaceArea(), MSDevice_Battery::setInternalMomentOfInertia(), GNEJunction::setLogicValid(), MSDevice_Battery::setMass(), MSDevice_Battery::setMaximumBatteryCapacity(), NIXMLEdgesHandler::setNodes(), MSLane::setPartialOccupation(), MSDevice_Battery::setPowerMax(), MSDevice_Battery::setPropulsionEfficiency(), MSDevice_Battery::setRadialDragCoefficient(), MSDevice_Battery::setRecuperationEfficiency(), MSLink::setRequestInformation(), MSDevice_Battery::setRollDragCoefficient(), MSTLLogicControl::TLSLogicVariants::setStateInstantiatingOnline(), NBLoadedSUMOTLDef::setTLControllingInformation(), NBOwnTLDef::setTLControllingInformation(), NBTrafficLightLogicCont::setTLControllingInformation(), NBLoadedTLDef::setTLControllingInformation(), NBEdge::shiftPositionAtNode(), NBEdgeCont::splitAt(), MSLane::succLinkSec(), GUITrafficLightLogicWrapper::switchTLSLogic(), MELoop::teleportVehicle(), METriggeredCalibrator::tryEmit(), MSSOTLTrafficLightLogic::trySwitch(), MSVehicle::updateBestLanes(), MSSOTLTrafficLightLogic::updateCTS(), GNETLSEditorFrame::updateDescription(), MSSwarmTrafficLightLogic::updatePheromoneLevels(), MSSwarmTrafficLightLogic::updateSensitivities(), MSDevice_BTreceiver::BTreceiverUpdate::updateVisibility(), TraCIServerAPI_Vehicle::vtdMap(), MSPModel_Striping::PState::walk(), MSLCM_LC2013::wantsChange(), MSLCM_SL2015::wantsChangeSublane(), MSBatteryExport::write(), MSEmissionExport::write(), MSFCDExport::write(), MSInstantInductLoop::write(), MSLink::writeApproaching(), 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(), MSFCDExport::writeTransportable(), RODFDetectorCon::writeValidationDetectors(), MSFullExport::writeVehicles(), PointOfInterest::writeXML(), SUMO::Polygon::writeXML(), MSRouteProbe::writeXMLOutput(), MSE2Collector::writeXMLOutput(), MSInductLoop::writeXMLOutput(), and RONet::~RONet().

§ getIDSecure()

§ getLane()

§ getPosition()

§ getTimestepsSinceLastDetection()

SUMOReal MSInductLoop::getTimestepsSinceLastDetection ( ) const
inherited

Returns the time since the last vehicle left the detector.

Returns
Timesteps from last leaving (detection) of the detector

Definition at line 212 of file MSInductLoop.cpp.

References MSNet::getInstance(), MSInductLoop::myLastLeaveTime, MSInductLoop::myVehiclesOnDet, and STEPS2TIME.

Referenced by MSActuatedTrafficLightLogic::gapControl(), GUIInductLoop::MyWrapper::getParameterWindow(), MSInductLoop::getPosition(), and TraCIServerAPI_InductionLoop::processGet().

§ isTyped()

bool MSDetectorFileOutput::isTyped ( ) const
inlineinherited

Checks whether the detector is type specific.

Returns
whether vehicle types are considered

Definition at line 155 of file MSDetectorFileOutput.h.

References MSDetectorFileOutput::myVehicleTypes.

Referenced by MSMeanData_Amitran::MSLaneMeanDataValues::write().

§ leaveDetectorByLaneChange()

void GUIInductLoop::leaveDetectorByLaneChange ( SUMOVehicle veh,
SUMOReal  lastPos 
)
protectedvirtual

Removes a vehicle from the detector's map myVehiclesOnDet.

Locks the internal mutex before calling MSInductLoop::leaveDetectorByLaneChange()

See also
MSInductLoop::leaveDetectorByLaneChange()
Parameters
vehThe leaving vehicle.
lastPosThe last position of the leaving vehicle.

Reimplemented from MSInductLoop.

Definition at line 89 of file GUIInductLoop.cpp.

References MSInductLoop::leaveDetectorByLaneChange(), and myLock.

§ leaveDetectorByMove()

void GUIInductLoop::leaveDetectorByMove ( SUMOVehicle veh,
SUMOReal  leaveTimestep 
)
protectedvirtual

Processes a vehicle that leaves the detector.

Locks the internal mutex before calling MSInductLoop::leaveDetectorByMove()

See also
MSInductLoop::leaveDetectorByMove()
Parameters
vehThe leaving vehicle.
leaveTimestepTimestep (not necessary integer) of leaving.
See also
MSInductLoop::leaveDetectorByMove()

Reimplemented from MSInductLoop.

Definition at line 83 of file GUIInductLoop.cpp.

References MSInductLoop::leaveDetectorByMove(), and myLock.

§ lengthSum()

static SUMOReal MSInductLoop::lengthSum ( SUMOReal  sumSoFar,
const MSInductLoop::VehicleData data 
)
inlinestaticprotectedinherited

§ notifyEnter()

bool MSInductLoop::notifyEnter ( SUMOVehicle veh,
Notification  reason 
)
virtualinherited

Checks whether the reminder is activated by a vehicle entering the lane.

Lane change means in this case that the vehicle changes to the lane the reminder is placed at.

Parameters
[in]vehThe entering vehicle.
[in]reasonhow the vehicle enters the lane
Returns
True if vehicle enters the induction loop
See also
Notification

Reimplemented from MSMoveReminder.

Definition at line 87 of file MSInductLoop.cpp.

References SUMOVehicle::getBackPositionOnLane(), SUMOVehicle::getPositionOnLane(), MSInductLoop::myEnteredVehicleNumber, MSMoveReminder::myLane, MSInductLoop::myPosition, MSInductLoop::myVehiclesOnDet, MSMoveReminder::NOTIFICATION_DEPARTED, MSMoveReminder::NOTIFICATION_LANE_CHANGE, MSMoveReminder::NOTIFICATION_PARKING, MSMoveReminder::NOTIFICATION_TELEPORT, SIMTIME, and MSDetectorFileOutput::vehicleApplies().

Referenced by MSInductLoop::getPosition().

§ notifyLeave()

bool MSInductLoop::notifyLeave ( SUMOVehicle veh,
SUMOReal  lastPos,
MSMoveReminder::Notification  reason 
)
virtualinherited

Dismisses the vehicle if it is on the detector due to a lane change.

If the vehicle is on the detector, it will be dismissed by incrementing myDismissedVehicleNumber and removing this vehicle's entering time from myVehiclesOnDet.

Parameters
[in]vehThe leaving vehicle.
[in]lastPosPosition on the lane when leaving.
[in]isArrivalwhether the vehicle arrived at its destination
[in]isLaneChangewhether the vehicle changed from the lane
See also
leaveDetectorByLaneChange
MSMoveReminder
MSMoveReminder::notifyLeave

Reimplemented from MSMoveReminder.

Definition at line 148 of file MSInductLoop.cpp.

References MSInductLoop::leaveDetectorByLaneChange(), MSMoveReminder::NOTIFICATION_JUNCTION, and SUMOReal.

Referenced by MSInductLoop::getPosition().

§ notifyMove()

bool MSInductLoop::notifyMove ( SUMOVehicle veh,
SUMOReal  oldPos,
SUMOReal  newPos,
SUMOReal  newSpeed 
)
virtualinherited

Checks whether the vehicle shall be counted and/or shall still touch this MSMoveReminder.

As soon a vehicle enters the detector, its entry time is computed and stored in myVehiclesOnDet via enterDetectorByMove. If it passes the detector, the according leaving time is computed and stored, too, using leaveDetectorByMove.

Parameters
[in]vehVehicle that asks this remider.
[in]oldPosPosition before move.
[in]newPosPosition after move with newSpeed.
[in]newSpeedMoving speed.
Returns
True if vehicle hasn't passed the detector completely.
See also
MSMoveReminder
MSMoveReminder::notifyMove
enterDetectorByMove
leaveDetectorByMove

Reimplemented from MSMoveReminder.

Definition at line 105 of file MSInductLoop.cpp.

References MSInductLoop::enterDetectorByMove(), MSVehicleType::getLength(), SUMOVehicle::getPreviousSpeed(), SUMOVehicle::getVehicleType(), MSGlobals::gSemiImplicitEulerUpdate, MSInductLoop::leaveDetectorByMove(), MSInductLoop::myPosition, MSInductLoop::myVehiclesOnDet, MSCFModel::passingTime(), SIMTIME, and SUMOReal.

Referenced by MSInductLoop::getPosition().

§ notifyMoveInternal()

virtual void MSMoveReminder::notifyMoveInternal ( const SUMOVehicle veh,
const SUMOReal  frontOnLane,
const SUMOReal  timeOnLane,
const SUMOReal  meanSpeedFrontOnLane,
const SUMOReal  meanSpeedVehicleOnLane,
const SUMOReal  travelledDistanceFrontOnLane,
const SUMOReal  travelledDistanceVehicleOnLane 
)
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.

Parameters
[in]vehVehicle that asks this reminder.
[in]frontOnLanetime the front of the vehicle spent on the lane.
[in]timeOnLanetime some part of the vehicle spent on the lane.
[in]meanSpeedFrontOnLaneAverage speed for the time that the front is on the lane.
[in]meanSpeedVehicleOnLaneAverage speed for the time that the vehicle is on the lane (with front or back).
[in]travelledDistanceFrontOnLanedistance travelled while overlapping with the lane.
[in]travelledDistanceVehicleOnLanedistance travelled while front was on the lane.

Reimplemented in MSMeanData::MeanDataValueTracker, MSDevice_Tripinfo, MSMeanData_Net::MSLaneMeanDataValues, MSMeanData_Amitran::MSLaneMeanDataValues, MSMeanData_Harmonoise::MSLaneMeanDataValues, and MSMeanData_Emissions::MSLaneMeanDataValues.

Definition at line 205 of file MSMoveReminder.h.

References UNUSED_PARAMETER.

Referenced by MSMeanData::MeanDataValues::notifyMove(), and MSMoveReminder::updateDetector().

§ removeFromVehicleUpdateValues()

void MSMoveReminder::removeFromVehicleUpdateValues ( SUMOVehicle veh)
protectedinherited

§ reset()

void GUIInductLoop::reset ( )
virtual

Resets all generated values to allow computation of next interval.

Locks the internal mutex before calling MSInductLoop::reset()

See also
MSInductLoop::reset()

Reimplemented from MSInductLoop.

Definition at line 70 of file GUIInductLoop.cpp.

References myLock, and MSInductLoop::reset().

§ setDescription()

void MSMoveReminder::setDescription ( const std::string &  description)
inlineinherited

§ setID()

void Named::setID ( const std::string &  newID)
inlineinherited

resets the id

Parameters
[in]newIDThe new id of this object

Definition at line 74 of file Named.h.

References Named::myID.

Referenced by NBNodeCont::mapToNumericalIDs(), NBEdgeCont::mapToNumericalIDs(), NBNodeCont::rename(), and NBEdgeCont::rename().

§ speedSum()

static SUMOReal MSInductLoop::speedSum ( SUMOReal  sumSoFar,
const MSInductLoop::VehicleData data 
)
inlinestaticprotectedinherited

§ updateDetector()

void MSMoveReminder::updateDetector ( SUMOVehicle veh,
SUMOReal  entryPos,
SUMOReal  leavePos,
SUMOTime  entryTime,
SUMOTime  currentTime,
SUMOTime  leaveTime,
bool  cleanUp 
)
inherited

§ vehicleApplies()

bool MSDetectorFileOutput::vehicleApplies ( const SUMOVehicle veh) const
inlineinherited

§ writeXMLDetectorProlog()

void MSInductLoop::writeXMLDetectorProlog ( OutputDevice dev) const
virtualinherited

Opens the XML-output using "detector" as root element.

Parameters
[in]devThe output device to write the root into
See also
MSDetectorFileOutput::writeXMLDetectorProlog
Exceptions
IOErrorIf an error on writing occurs (!!! not yet implemented)

Implements MSDetectorFileOutput.

Definition at line 222 of file MSInductLoop.cpp.

References OutputDevice::writeXMLHeader().

Referenced by MSInductLoop::getPosition().

§ writeXMLOutput()

void MSInductLoop::writeXMLOutput ( OutputDevice dev,
SUMOTime  startTime,
SUMOTime  stopTime 
)
virtualinherited

Writes collected values into the given stream.

Parameters
[in]devThe output device to write the data into
[in]startTimeFirst time step the data were gathered
[in]stopTimeLast time step the data were gathered
See also
MSDetectorFileOutput::writeXMLOutput
Exceptions
IOErrorIf an error on writing occurs (!!! not yet implemented)

Implements MSDetectorFileOutput.

Definition at line 228 of file MSInductLoop.cpp.

References OutputDevice::closeTag(), StringUtils::escapeXML(), Named::getID(), MSInductLoop::lengthSum(), MAX2(), MIN2(), MSInductLoop::myEnteredVehicleNumber, MSInductLoop::myVehicleDataCont, MSInductLoop::myVehiclesOnDet, OutputDevice::openTag(), MSInductLoop::reset(), MSInductLoop::speedSum(), STEPS2TIME, SUMO_ATTR_BEGIN, SUMO_ATTR_END, SUMO_ATTR_ID, SUMO_TAG_INTERVAL, SUMOReal, and OutputDevice::writeAttr().

Referenced by MSInductLoop::getPosition().

Field Documentation

§ myDescription

std::string MSMoveReminder::myDescription
protectedinherited

a description of this moveReminder

Definition at line 237 of file MSMoveReminder.h.

Referenced by MSMoveReminder::getDescription(), and MSMoveReminder::setDescription().

§ myEnteredVehicleNumber

int MSInductLoop::myEnteredVehicleNumber
protectedinherited

The number of entered vehicles.

Definition at line 351 of file MSInductLoop.h.

Referenced by MSInductLoop::enterDetectorByMove(), MSInductLoop::notifyEnter(), MSInductLoop::reset(), and MSInductLoop::writeXMLOutput().

§ myID

§ myLane

§ myLastLeaveTime

SUMOReal MSInductLoop::myLastLeaveTime
protectedinherited

Leave-time of the last vehicle detected [s].

Definition at line 345 of file MSInductLoop.h.

Referenced by MSInductLoop::getTimestepsSinceLastDetection(), and MSInductLoop::leaveDetectorByMove().

§ myLastOccupancy

SUMOReal MSInductLoop::myLastOccupancy
protectedinherited

Occupancy by the last vehicle detected.

Definition at line 348 of file MSInductLoop.h.

Referenced by MSInductLoop::leaveDetectorByMove().

§ myLastVehicleDataCont

VehicleDataCont MSInductLoop::myLastVehicleDataCont
protectedinherited

Data of vehicles that have completely passed the detector in the last time interval.

Definition at line 361 of file MSInductLoop.h.

Referenced by MSInductLoop::collectVehiclesOnDet(), and MSInductLoop::reset().

§ myLock

MFXMutex GUIInductLoop::myLock
mutable

Mutex preventing parallel read/write access to internal MSInductLoop state.

Definition at line 212 of file GUIInductLoop.h.

Referenced by collectVehiclesOnDet(), enterDetectorByMove(), leaveDetectorByLaneChange(), leaveDetectorByMove(), and reset().

§ myPosition

const SUMOReal MSInductLoop::myPosition
protectedinherited

§ myVehicleDataCont

VehicleDataCont MSInductLoop::myVehicleDataCont
protectedinherited

Data of vehicles that have completely passed the detector.

Definition at line 358 of file MSInductLoop.h.

Referenced by MSInductLoop::collectVehiclesOnDet(), MSInductLoop::leaveDetectorByMove(), MSInductLoop::reset(), and MSInductLoop::writeXMLOutput().

§ myVehiclesOnDet

§ myVehicleTypes

std::set<std::string> MSDetectorFileOutput::myVehicleTypes
protectedinherited

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