34 myDescription(description)
36 , myNotificationMutex(true)
39 if (
myLane !=
nullptr && doAdd) {
53 if (entryTime > currentTime) {
61 const SUMOTime previousEntryTime = j->second.first;
62 if (previousEntryTime <= currentTime) {
63 entryTime = previousEntryTime;
64 entryPos = j->second.second;
67 assert(entryTime <= currentTime);
68 if ((entryTime < leaveTime) && (entryPos <= leavePos)) {
69 const double timeOnLane =
STEPS2TIME(currentTime - entryTime);
70 const double speed = (leavePos - entryPos) /
STEPS2TIME(leaveTime - entryTime);
72 assert(timeOnLane >= 0);
73 notifyMoveInternal(veh, timeOnLane, timeOnLane, speed, speed, speed * timeOnLane, speed * timeOnLane, 0.);
Representation of a lane in the micro simulation.
virtual void addMoveReminder(MSMoveReminder *rem)
Add a move-reminder to move-reminder container.
virtual void notifyMoveInternal(const SUMOTrafficObject &veh, const double frontOnLane, const double timeOnLane, const double meanSpeedFrontOnLane, const double meanSpeedVehicleOnLane, const double travelledDistanceFrontOnLane, const double travelledDistanceVehicleOnLane, const double meanLengthOnLane)
Internal notification about the vehicle moves.
std::map< long long int, std::pair< SUMOTime, double > > myLastVehicleUpdateValues
MSMoveReminder(const std::string &description, MSLane *const lane=nullptr, const bool doAdd=true)
Constructor.
MSLane * myLane
Lane on which the reminder works.
void removeFromVehicleUpdateValues(SUMOTrafficObject &veh)
void updateDetector(SUMOTrafficObject &veh, double entryPos, double leavePos, SUMOTime entryTime, SUMOTime currentTime, SUMOTime leaveTime, bool cleanUp)
Representation of a vehicle, person, or container.
virtual NumericalID getNumericalID() const =0
return the numerical ID which is only for internal usage