![]() |
SUMO - Simulation of Urban MObility
|
Representation of a lane in the micro simulation. More...
#include <MSLane.h>
Data Structures | |
class | AnyVehicleIterator |
class | by_connections_to_sorter |
class | edge_finder |
struct | IncomingLaneInfo |
class | vehicle_natural_position_sorter |
class | vehicle_position_sorter |
Sorts vehicles by their position (descending) More... | |
struct | VehPosition |
Public Types | |
enum | CollisionAction { COLLISION_ACTION_NONE, COLLISION_ACTION_WARN, COLLISION_ACTION_TELEPORT, COLLISION_ACTION_REMOVE } |
typedef std::vector< MSVehicle * > | VehCont |
Container for vehicles. More... | |
Public Member Functions | |
void | addApproachingLane (MSLane *lane, bool warnMultiCon) |
void | addIncomingLane (MSLane *lane, MSLink *viaLink) |
void | addParameter (const std::string &key, const std::string &value) |
Adds a parameter. More... | |
void | addParameter (const std::map< std::string, std::string > &mapArg) |
Adds all given parameter. More... | |
void | addParameter (const Parameterised &p) |
Adds all given parameter. More... | |
void | addTo (const StoringVisitor &cont) const |
Adds this object to the given container. More... | |
bool | allowsVehicleClass (SUMOVehicleClass vclass) const |
virtual bool | appropriate (const MSVehicle *veh) |
void | clearParameter () |
Clears the parameter map. More... | |
virtual void | detectCollisions (SUMOTime timestep, const std::string &stage) |
Check if vehicles are too close. More... | |
bool | empty () const |
Returns true if there is not a single vehicle on the lane. More... | |
void | enteredByLaneChange (MSVehicle *v) |
SUMOReal | getCenterOnEdge () const |
std::pair< MSVehicle *const, SUMOReal > | getCriticalLeader (SUMOReal dist, SUMOReal seen, SUMOReal speed, const MSVehicle &veh) const |
Returns the most dangerous leader and the distance to him. More... | |
int | getCrossingIndex () const |
return the index of the link to the next crossing if this is walkingArea, else -1 More... | |
MSEdge & | getEdge () const |
Returns the lane's edge. More... | |
MSVehicle * | getFirstAnyVehicle () const |
returns the first vehicle that is fully or partially on this lane More... | |
MSVehicle * | getFirstFullVehicle () const |
returns the first vehicle for which this lane is responsible or 0 More... | |
std::pair< MSVehicle *const, SUMOReal > | getFollower (const MSVehicle *ego, SUMOReal egoPos, SUMOReal dist) const |
Find follower vehicle for the given ego vehicle (which may be on the opposite direction lane) More... | |
std::pair< MSVehicle *const, SUMOReal > | getFollowerOnConsecutive (SUMOReal backOffset, SUMOReal leaderSpeed, SUMOReal leaderMaxDecel, SUMOReal dist=-1) const |
return the follower with the largest missing rear gap among all predecessor lanes (within dist) More... | |
MSLeaderDistanceInfo | getFollowersOnConsecutive (const MSVehicle *ego, bool allSublanes) const |
return the sublane followers with the largest missing rear gap among all predecessor lanes (within dist) More... | |
const std::string & | getID () const |
Returns the id. More... | |
const std::vector< IncomingLaneInfo > & | getIncomingLanes () const |
LinkState | getIncomingLinkState () const |
get the state of the link from the logical predecessor to this lane More... | |
const MSEdge * | getInternalFollower () const |
Returns the lane's follower if it is an internal lane, the edge of the lane otherwise. More... | |
MSVehicle * | getLastAnyVehicle () const |
returns the last vehicle that is fully or partially on this lane More... | |
MSVehicle * | getLastFullVehicle () const |
returns the last vehicle for which this lane is responsible or 0 More... | |
std::pair< MSVehicle *const, SUMOReal > | getLeader (const MSVehicle *veh, const SUMOReal vehPos, const std::vector< MSLane *> &bestLaneConts, SUMOReal dist=-1, bool checkTmpVehicles=false) const |
Returns the immediate leader of veh and the distance to veh starting on this lane. More... | |
std::pair< MSVehicle *const, SUMOReal > | getLeaderOnConsecutive (SUMOReal dist, SUMOReal seen, SUMOReal speed, const MSVehicle &veh, const std::vector< MSLane *> &bestLaneConts) const |
Returns the immediate leader and the distance to him. More... | |
void | getLeadersOnConsecutive (SUMOReal dist, SUMOReal seen, SUMOReal speed, const MSVehicle *ego, const std::vector< MSLane *> &bestLaneConts, MSLeaderDistanceInfo &result) const |
Returns the immediate leaders and the distance to them (as getLeaderOnConsecutive but for the sublane case) More... | |
const MSLinkCont & | getLinkCont () const |
returns the container with all links !!! More... | |
MSLane * | getLogicalPredecessorLane () const |
get the most likely precedecessor lane (sorted using by_connections_to_sorter). The result is cached in myLogicalPredecessorLane More... | |
MSLane * | getLogicalPredecessorLane (const MSEdge &fromEdge) const |
return the (first) predecessor lane from the given edge More... | |
const std::map< std::string, std::string > & | getMap () const |
Returns the inner key/value map. More... | |
SUMOReal | getMissingRearGap (SUMOReal backOffset, SUMOReal leaderSpeed, SUMOReal leaderMaxDecel) const |
return by how much further the leader must be inserted to avoid rear end collisions More... | |
MSLane * | getOpposite () const |
return the opposite direction lane for lane changing or 0 More... | |
std::pair< MSVehicle *const, SUMOReal > | getOppositeFollower (const MSVehicle *ego) const |
std::pair< MSVehicle *const, SUMOReal > | getOppositeLeader (const MSVehicle *ego, SUMOReal dist) const |
SUMOReal | getOppositePos (SUMOReal pos) const |
return the corresponding position on the opposite lane More... | |
std::vector< const MSLane * > | getOutgoingLanes () const |
get the list of outgoing lanes More... | |
MSLane * | getParallelLane (int offset) const |
Returns the lane with the given offset parallel to this one or 0 if it does not exist. More... | |
const std::string & | getParameter (const std::string &key, const std::string &defaultValue) const |
Returns the value for a given key. More... | |
MSVehicle * | getPartialBehind (const MSVehicle *ego) const |
int | getRightmostSublane () const |
SUMOReal | getRightSideOnEdge () const |
bool | isApproachedFrom (MSEdge *const edge) |
bool | isApproachedFrom (MSEdge *const edge, MSLane *const lane) |
bool | isEmpty () const |
bool | isInternal () const |
bool | isLinkEnd (MSLinkCont::const_iterator &i) const |
bool | isLinkEnd (MSLinkCont::iterator &i) |
bool | knowsParameter (const std::string &key) const |
Returns whether the parameter is known. More... | |
void | leftByLaneChange (MSVehicle *v) |
MSLane (const std::string &id, SUMOReal maxSpeed, SUMOReal length, MSEdge *const edge, int numericalID, const PositionVector &shape, SUMOReal width, SVCPermissions permissions, int index) | |
Constructor. More... | |
virtual MSVehicle * | removeVehicle (MSVehicle *remVehicle, MSMoveReminder::Notification notification, bool notify=true) |
void | resetPermissions (long transientID) |
void | setID (const std::string &newID) |
resets the id More... | |
void | setLength (SUMOReal val) |
Sets a new length for the lane (used by TraCI only) More... | |
void | setMaxSpeed (SUMOReal val) |
Sets a new maximum speed for the lane (used by TraCI and MSCalibrator) More... | |
void | setPermissions (SVCPermissions permissions, long transientID) |
Sets the permissions to the given value. If a transientID is given, the permissions are recored as temporary. More... | |
void | setRightSideOnEdge (SUMOReal value, int rightmostSublane) |
void | sortPartialVehicles () |
sorts myPartialVehicles More... | |
void | visit (const TraCIServerAPI_Lane::StoringVisitor &cont) const |
Callback for visiting the lane when traversing an RTree. More... | |
virtual | ~MSLane () |
Destructor. More... | |
Additional initialisation | |
void | addLink (MSLink *link) |
Delayed initialization. More... | |
void | addNeigh (const std::string &id) |
Adds a neighbor to this lane. More... | |
interaction with MSMoveReminder | |
virtual void | addMoveReminder (MSMoveReminder *rem) |
Add a move-reminder to move-reminder container. More... | |
const std::vector< MSMoveReminder *> & | getMoveReminders () const |
Return the list of this lane's move reminders. More... | |
Vehicle insertion | |
bool | insertVehicle (MSVehicle &v) |
Tries to insert the given vehicle. More... | |
bool | isInsertionSuccess (MSVehicle *vehicle, SUMOReal speed, SUMOReal pos, SUMOReal posLat, bool recheckNextLanes, MSMoveReminder::Notification notification) |
Tries to insert the given vehicle with the given state (speed and pos) More... | |
bool | checkFailure (MSVehicle *aVehicle, SUMOReal &speed, SUMOReal &dist, const SUMOReal nspeed, const bool patchSpeed, const std::string errorMsg) const |
bool | lastInsertion (MSVehicle &veh, SUMOReal mspeed) |
bool | freeInsertion (MSVehicle &veh, SUMOReal speed, MSMoveReminder::Notification notification=MSMoveReminder::NOTIFICATION_DEPARTED) |
Tries to insert the given vehicle on any place. More... | |
void | forceVehicleInsertion (MSVehicle *veh, SUMOReal pos, MSMoveReminder::Notification notification, SUMOReal posLat=0) |
Inserts the given vehicle at the given position. More... | |
Handling vehicles lapping into lanes | |
virtual SUMOReal | setPartialOccupation (MSVehicle *v) |
Sets the information about a vehicle lapping into this lane. More... | |
virtual void | resetPartialOccupation (MSVehicle *v) |
Removes the information about a vehicle lapping into this lane. More... | |
const MSLeaderInfo & | getLastVehicleInformation (const MSVehicle *ego, SUMOReal latOffset, SUMOReal minPos=0, bool allowCached=true) const |
Returns the last vehicles on the lane. More... | |
const MSLeaderInfo & | getFirstVehicleInformation (const MSVehicle *ego, SUMOReal latOffset, bool onlyFrontOnLane, SUMOReal maxPos=std::numeric_limits< SUMOReal >::max(), bool allowCached=true) const |
analogue to getLastVehicleInformation but in the upstream direction More... | |
Access to vehicles | |
int | getVehicleNumber () const |
Returns the number of vehicles on this lane (for which this lane is responsible) More... | |
int | getVehicleNumberWithPartials () const |
Returns the number of vehicles on this lane (including partial occupators) More... | |
int | getPartialVehicleNumber () const |
Returns the number of vehicles partially on this lane (for which this lane is not responsible) More... | |
virtual const VehCont & | getVehiclesSecure () const |
Returns the vehicles container; locks it for microsimulation. More... | |
AnyVehicleIterator | anyVehiclesBegin () const |
begin iterator for iterating over all vehicles touching this lane in downstream direction More... | |
AnyVehicleIterator | anyVehiclesEnd () const |
end iterator for iterating over all vehicles touching this lane in downstream direction More... | |
AnyVehicleIterator | anyVehiclesUpstreamBegin () const |
begin iterator for iterating over all vehicles touching this lane in upstream direction More... | |
AnyVehicleIterator | anyVehiclesUpstreamEnd () const |
end iterator for iterating over all vehicles touching this lane in upstream direction More... | |
virtual void | releaseVehicles () const |
Allows to use the container for microsimulation again. More... | |
Atomar value getter | |
int | getNumericalID () const |
Returns this lane's numerical id. More... | |
const PositionVector & | getShape () const |
Returns this lane's shape. More... | |
SUMOReal | getLengthGeometryFactor () const |
return shape.length() / myLength More... | |
SUMOReal | interpolateLanePosToGeometryPos (SUMOReal lanePos) const |
const Position | geometryPositionAtOffset (SUMOReal offset, SUMOReal lateralOffset=0) const |
SUMOReal | interpolateGeometryPosToLanePos (SUMOReal geometryPos) const |
SUMOReal | getVehicleMaxSpeed (const SUMOVehicle *const veh) const |
Returns the lane's maximum speed, given a vehicle's speed limit adaptation. More... | |
SUMOReal | getSpeedLimit () const |
Returns the lane's maximum allowed speed. More... | |
SUMOReal | getLength () const |
Returns the lane's length. More... | |
SVCPermissions | getPermissions () const |
Returns the vehicle class permissions for this lane. More... | |
SUMOReal | getWidth () const |
Returns the lane's width. More... | |
int | getIndex () const |
Returns the lane's index. More... | |
Vehicle movement (longitudinal) | |
virtual void | planMovements (const SUMOTime t) |
Compute safe velocities for all vehicles based on positions and speeds from the last time step. Also registers ApproachingVehicleInformation for all links. More... | |
virtual bool | executeMovements (SUMOTime t, std::vector< MSLane *> &lanesWithVehiclesToIntegrate) |
Executes planned vehicle movements with regards to right-of-way. More... | |
virtual bool | integrateNewVehicle (SUMOTime t) |
Insert buffered vehicle into the real lane. More... | |
Current state retrieval | |
SUMOReal | getMeanSpeed () const |
Returns the mean speed on this lane. More... | |
SUMOReal | getWaitingSeconds () const |
Returns the overall waiting time on this lane. More... | |
SUMOReal | getBruttoOccupancy () const |
Returns the brutto (including minGaps) occupancy of this lane during the last step. More... | |
SUMOReal | getNettoOccupancy () const |
Returns the netto (excluding minGaps) occupancy of this lane during the last step (including minGaps) More... | |
SUMOReal | getBruttoVehLenSum () const |
Returns the sum of lengths of vehicles, including their minGaps, which were on the lane during the last step. More... | |
SUMOReal | getCO2Emissions () const |
Returns the sum of last step CO2 emissions. More... | |
SUMOReal | getCOEmissions () const |
Returns the sum of last step CO emissions. More... | |
SUMOReal | getPMxEmissions () const |
Returns the sum of last step PMx emissions. More... | |
SUMOReal | getNOxEmissions () const |
Returns the sum of last step NOx emissions. More... | |
SUMOReal | getHCEmissions () const |
Returns the sum of last step HC emissions. More... | |
SUMOReal | getFuelConsumption () const |
Returns the sum of last step fuel consumption. More... | |
SUMOReal | getElectricityConsumption () const |
Returns the sum of last step electricity consumption. More... | |
SUMOReal | getHarmonoise_NoiseEmissions () const |
Returns the sum of last step noise emissions. More... | |
State saving/loading | |
void | saveState (OutputDevice &out) |
Saves the state of this lane into the given stream. More... | |
void | loadState (std::vector< std::string > &vehIDs, MSVehicleControl &vc) |
Loads the state of this segment with the given parameters. More... | |
Static Public Member Functions | |
static void | clear () |
Clears the dictionary. More... | |
static bool | dictionary (const std::string &id, MSLane *lane) |
Static (sic!) container methods {. More... | |
static MSLane * | dictionary (const std::string &id) |
Returns the MSLane associated to the key id. More... | |
static int | dictSize () |
Returns the number of stored lanes. More... | |
template<class RTREE > | |
static void | fill (RTREE &into) |
Fills the given RTree with lane instances. More... | |
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 | initCollisionOptions (const OptionsCont &oc) |
static void | insertIDs (std::vector< std::string > &into) |
Adds the ids of all stored lanes into the given vector. More... | |
static MSLinkCont::const_iterator | succLinkSec (const SUMOVehicle &veh, int nRouteSuccs, const MSLane &succLinkSource, const std::vector< MSLane *> &conts) |
static bool | teleportOnCollision () |
Static Public Attributes | |
static const long | CHANGE_PERMISSIONS_GUI = 1 |
static const long | CHANGE_PERMISSIONS_PERMANENT = 0 |
Protected Types | |
typedef std::map< std::string, MSLane *> | DictType |
definition of the static dictionary type More... | |
Protected Member Functions | |
SUMOReal | basePos (const MSVehicle &veh) const |
departure position where the vehicle fits fully onto the lane (if possible) More... | |
bool | detectCollisionBetween (SUMOTime timestep, const std::string &stage, const MSVehicle *collider, const MSVehicle *victim, std::set< const MSVehicle *, SUMOVehicle::ComparatorIdLess > &toRemove, std::set< const MSVehicle *> &toTeleport) const |
detect whether there is a collision between the two vehicles More... | |
SUMOReal | getDepartSpeed (const MSVehicle &veh, bool &patchSpeed) |
SUMOReal | getMaximumBrakeDist () const |
compute maximum braking distance on this lane More... | |
void | handleCollisionBetween (SUMOTime timestep, const std::string &stage, const MSVehicle *collider, const MSVehicle *victim, SUMOReal gap, SUMOReal latGap, std::set< const MSVehicle *, SUMOVehicle::ComparatorIdLess > &toRemove, std::set< const MSVehicle *> &toTeleport) const |
take action upon collision More... | |
virtual void | incorporateVehicle (MSVehicle *veh, SUMOReal pos, SUMOReal speed, SUMOReal posLat, const MSLane::VehCont::iterator &at, MSMoveReminder::Notification notification=MSMoveReminder::NOTIFICATION_DEPARTED) |
Inserts the vehicle into this lane, and informs it about entering the network. More... | |
SUMOReal | safeInsertionSpeed (const MSVehicle *veh, const MSLeaderInfo &leaders, SUMOReal speed) |
return the maximum safe speed for insertion behind leaders (a negative value indicates that safe insertion is impossible) More... | |
virtual void | swapAfterLaneChange (SUMOTime t) |
moves myTmpVehicles int myVehicles after a lane change procedure More... | |
Protected Attributes | |
std::map< MSEdge *, std::vector< MSLane * > > | myApproachingLanes |
SUMOReal | myBruttoVehicleLengthSum |
The current length of all vehicles on this lane, including their minGaps. More... | |
MSEdge *const | myEdge |
The lane's edge, for routing only. More... | |
MSLeaderInfo | myFollowerInfo |
followers on all sublanes as seen by vehicles on consecutive lanes (cached) More... | |
SUMOTime | myFollowerInfoTime |
time step for which myFollowerInfo was last updated More... | |
std::string | myID |
The name of the object. More... | |
std::vector< IncomingLaneInfo > | myIncomingLanes |
int | myIndex |
The lane index. More... | |
MSLeaderInfo | myLeaderInfo |
leaders on all sublanes as seen by approaching vehicles (cached) More... | |
SUMOTime | myLeaderInfoTime |
time step for which myLeaderInfo was last updated More... | |
MSLeaderInfo | myLeaderInfoTmp |
SUMOReal | myLength |
Lane length [m]. More... | |
const SUMOReal | myLengthGeometryFactor |
precomputed myShape.length / myLength More... | |
MSLinkCont | myLinks |
MSLane * | myLogicalPredecessorLane |
SUMOReal | myMaxSpeed |
Lane-wide speedlimit [m/s]. More... | |
std::vector< std::string > | myNeighs |
SUMOReal | myNettoVehicleLengthSum |
The current length of all vehicles on this lane, excluding their minGaps. More... | |
int | myNumericalID |
Unique numerical ID (set on reading by netload) More... | |
SVCPermissions | myOriginalPermissions |
The original vClass permissions for this lane (before temporary modifications) More... | |
VehCont | myPartialVehicles |
The lane's partial vehicles. This container holds all vehicles that are partially on this lane but which are in myVehicles of another lane. Reasons for partial occupancie include the following. More... | |
std::map< long, SVCPermissions > | myPermissionChanges |
SVCPermissions | myPermissions |
The vClass permissions for this lane. More... | |
const std::map< SUMOVehicleClass, SUMOReal > * | myRestrictions |
The vClass speed restrictions for this lane. More... | |
int | myRightmostSublane |
the index of the rightmost sublane of this lane on myEdge More... | |
SUMOReal | myRightSideOnEdge |
the combined width of all lanes with lower index on myEdge More... | |
PositionVector | myShape |
The shape of the lane. More... | |
VehCont | myTmpVehicles |
Container for lane-changing vehicles. After completion of lane-change- process, the containers will be swapped with myVehicles. More... | |
VehCont | myVehBuffer |
Buffer for vehicles that moved from their previous lane onto this one. Integrated after all vehicles executed their moves. More... | |
VehCont | myVehicles |
The lane's vehicles. This container holds all vehicles that have their front (longitudinally) and their center (laterally) on this lane. These are the vehicles that this lane is 'responsibly' for (i.e. when executing movements) More... | |
const SUMOReal | myWidth |
Lane width [m]. More... | |
Static Protected Attributes | |
static DictType | myDict |
Static dictionary to associate string-ids with objects. More... | |
Private Member Functions | |
MSLane (const MSLane &) | |
invalidated copy constructor More... | |
MSLane & | operator= (const MSLane &) |
invalidated assignment operator More... | |
Private Attributes | |
std::vector< MSMoveReminder *> | myMoveReminders |
This lane's move reminder. More... | |
Static Private Attributes | |
static bool | myCheckJunctionCollisions |
static CollisionAction | myCollisionAction |
the action to take on collisions More... | |
Friends | |
class | AnyVehicleIterator |
class | MSLaneChanger |
needs access to myTmpVehicles (this maybe should be done via double-buffering!!!) More... | |
class | MSLaneChangerSublane |
class | MSQueueExport |
class | MSXMLRawOut |
Representation of a lane in the micro simulation.
Class which represents a single lane. Somekind of the main class of the simulation. Allows moving vehicles.
|
protected |
typedef std::vector<MSVehicle*> MSLane::VehCont |
MSLane::MSLane | ( | const std::string & | id, |
SUMOReal | maxSpeed, | ||
SUMOReal | length, | ||
MSEdge *const | edge, | ||
int | numericalID, | ||
const PositionVector & | shape, | ||
SUMOReal | width, | ||
SVCPermissions | permissions, | ||
int | index | ||
) |
Constructor.
[in] | id | The lane's id |
[in] | maxSpeed | The speed allowed on this lane |
[in] | length | The lane's length |
[in] | edge | The edge this lane belongs to |
[in] | numericalID | The numerical id of the lane |
[in] | shape | The shape of the lane |
[in] | width | The width of the lane |
[in] | permissions | Encoding of the Vehicle classes that may drive on this lane |
[in] | index | The index of this lane within its parent edge |
Definition at line 160 of file MSLane.cpp.
References MSEdge::getEdgeType(), MSNet::getInstance(), MSNet::getRestrictions(), and myRestrictions.
|
virtual |
|
private |
invalidated copy constructor
void MSLane::addApproachingLane | ( | MSLane * | lane, |
bool | warnMultiCon | ||
) |
Definition at line 1577 of file MSLane.cpp.
References MSEdge::EDGEFUNCTION_INTERNAL, getEdge(), Named::getID(), MSEdge::getPurpose(), myApproachingLanes, and WRITE_WARNING.
Referenced by NLHandler::addConnection(), and getIncomingLanes().
Definition at line 1567 of file MSLane.cpp.
References getLength(), MSLane::IncomingLaneInfo::lane, MSLane::IncomingLaneInfo::length, myIncomingLanes, and MSLane::IncomingLaneInfo::viaLink.
Referenced by NLHandler::addConnection(), and allowsVehicleClass().
void MSLane::addLink | ( | MSLink * | link | ) |
Delayed initialization.
Not all lane-members are known at the time the lane is born, above all the pointers to other lanes, so we have to add them later.
[in] | link | An outgoing link |
Definition at line 190 of file MSLane.cpp.
References myLinks.
Referenced by NLHandler::addConnection().
|
virtual |
Add a move-reminder to move-reminder container.
The move reminder will not be deleted by the lane.
[in] | rem | The move reminder to add |
Definition at line 203 of file MSLane.cpp.
References myMoveReminders, myVehicles, and SUMOReal.
Referenced by MSMoveReminder::MSMoveReminder().
void MSLane::addNeigh | ( | const std::string & | id | ) |
Adds a neighbor to this lane.
[in] | id | The lane's id |
Definition at line 196 of file MSLane.cpp.
References myNeighs.
|
inherited |
Adds a parameter.
[in] | key | The parameter's name |
[in] | value | The parameter's value |
Definition at line 53 of file Parameterised.cpp.
References Parameterised::myMap.
Referenced by SUMORouteHandler::addParam(), NLHandler::addParam(), PCLoaderOSM::addPOI(), PCLoaderOSM::addPolygon(), NBTrafficLightDefinition::compute(), NIImporter_OpenDrive::loadNetwork(), NIImporter_MATSim::EdgesHandler::myStartElement(), TraCIServerAPI_Edge::processSet(), TraCIServerAPI_TLS::processSet(), TraCIServerAPI_POI::processSet(), TraCIServerAPI_Polygon::processSet(), and TraCIServerAPI_Lane::processSet().
|
inherited |
Adds all given parameter.
[in] | mapArg | The keys/values to insert |
Definition at line 59 of file Parameterised.cpp.
References Parameterised::myMap.
|
inherited |
Adds all given parameter.
[in] | p | The keys/values to insert |
Definition at line 67 of file Parameterised.cpp.
References Parameterised::myMap.
|
inlineinherited |
Adds this object to the given container.
Definition at line 129 of file Named.h.
References Named::StoringVisitor::add().
|
inline |
Definition at line 695 of file MSLane.h.
References addIncomingLane(), and myPermissions.
Referenced by MSVehicle::addStop(), MSEdge::allowedLanes(), MSPModel_NonInteracting::PState::getPosition(), MSVehicle::updateBestLanes(), and MSLCM_SL2015::updateExpectedSublaneSpeeds().
|
inline |
begin iterator for iterating over all vehicles touching this lane in downstream direction
Definition at line 386 of file MSLane.h.
References AnyVehicleIterator, myPartialVehicles, and myVehicles.
Referenced by detectCollisions(), getFollowersOnConsecutive(), MSLink::getInternalLengthsAfter(), getLastVehicleInformation(), and getLeader().
|
inline |
end iterator for iterating over all vehicles touching this lane in downstream direction
Definition at line 391 of file MSLane.h.
References AnyVehicleIterator, myPartialVehicles, and myVehicles.
Referenced by detectCollisions(), getFollowersOnConsecutive(), MSLink::getInternalLengthsAfter(), and getLeader().
|
inline |
begin iterator for iterating over all vehicles touching this lane in upstream direction
Definition at line 396 of file MSLane.h.
References AnyVehicleIterator, myPartialVehicles, and myVehicles.
Referenced by getFirstVehicleInformation(), and getFollower().
|
inline |
end iterator for iterating over all vehicles touching this lane in upstream direction
Definition at line 401 of file MSLane.h.
References AnyVehicleIterator.
Referenced by getFollower().
|
virtual |
Returns the information whether this lane may be used to continue the current route
Definition at line 1344 of file MSLane.cpp.
References MSEdge::EDGEFUNCTION_INTERNAL, MSVehicle::getBestLanes(), MSVehicle::getBestLanesContinuation(), MSVehicle::getLaneIndex(), MSEdge::getPurpose(), myEdge, myLinks, MSBaseVehicle::succEdge(), and succLinkSec().
Referenced by executeMovements(), and getIndex().
departure position where the vehicle fits fully onto the lane (if possible)
Definition at line 483 of file MSLane.cpp.
References MSVehicleType::getLength(), MSBaseVehicle::getVehicleType(), MIN2(), myLength, and POSITION_EPS.
Referenced by insertVehicle(), and lastInsertion().
bool MSLane::checkFailure | ( | MSVehicle * | aVehicle, |
SUMOReal & | speed, | ||
SUMOReal & | dist, | ||
const SUMOReal | nspeed, | ||
const bool | patchSpeed, | ||
const std::string | errorMsg | ||
) | const |
Definition at line 488 of file MSLane.cpp.
References MSCFModel::brakeGap(), MSInsertionControl::descheduleDeparture(), MSVehicle::getCarFollowModel(), MSBaseVehicle::getID(), MSNet::getInsertionControl(), MSNet::getInstance(), MSVehicleType::getMinGap(), MSBaseVehicle::getVehicleType(), MIN2(), and WRITE_ERROR.
Referenced by getMoveReminders(), and isInsertionSuccess().
|
static |
Clears the dictionary.
Definition at line 1309 of file MSLane.cpp.
References myDict.
Referenced by MSNet::clearAll(), and getEdge().
|
inherited |
Clears the parameter map.
Definition at line 91 of file Parameterised.cpp.
References Parameterised::myMap.
|
protected |
detect whether there is a collision between the two vehicles
Definition at line 1086 of file MSLane.cpp.
References COLLISION_ACTION_TELEPORT, DELTA_T, MSVehicle::getBackPositionOnLane(), MSVehicle::getCenterOnEdge(), MSVehicle::getInfluencer(), MSVehicle::getLane(), MSVehicle::getLaneChangeModel(), MSVehicleType::getMinGap(), MSVehicle::getPositionOnLane(), MSBaseVehicle::getVehicleType(), MSVehicleType::getWidth(), MSGlobals::gLaneChangeDuration, MSGlobals::gLateralResolution, handleCollisionBetween(), MSVehicle::hasInfluencer(), MSAbstractLaneChangeModel::isChangingLanes(), MSVehicle::isFrontOnLane(), MSVehicle::Influencer::isVTDAffected(), myCollisionAction, NUMERICAL_EPS, and SUMOReal.
Referenced by detectCollisions().
|
virtual |
Check if vehicles are too close.
Reimplemented in GUILane.
Definition at line 979 of file MSLane.cpp.
References MSVehicleTransfer::add(), anyVehiclesBegin(), anyVehiclesEnd(), COLLISION_ACTION_NONE, detectCollisionBetween(), MSVehicle::getBoundingBox(), MSVehicle::getBoundingPoly(), MSVehicleTransfer::getInstance(), MSNet::getInstance(), MSVehicle::getLane(), MSVehicle::getLaneChangeModel(), getLastVehicleInformation(), MSVehicle::getPositionOnLane(), getRightSideOnEdge(), MSAbstractLaneChangeModel::getShadowLane(), MSNet::getVehicleControl(), MSGlobals::gLaneChangeDuration, MSGlobals::gLateralResolution, handleCollisionBetween(), MSEdge::isInternal(), myCheckJunctionCollisions, myCollisionAction, myEdge, myLinks, myPartialVehicles, myVehicles, MSMoveReminder::NOTIFICATION_TELEPORT, MSMoveReminder::NOTIFICATION_VAPORIZED, MSLeaderInfo::numSublanes(), MSVehicle::onRemovalFromNet(), PositionVector::overlapsWith(), removeVehicle(), and MSVehicleControl::scheduleVehicleRemoval().
Referenced by GUILane::detectCollisions(), and getIndex().
|
static |
Static (sic!) container methods {.
Inserts a MSLane into the static dictionary
Returns true if the key id isn't already in the dictionary. Otherwise returns false.
[in] | id | The id of the lane |
[in] | lane | The lane itself |
make non-static
why is the id given? The lane is named
Definition at line 1286 of file MSLane.cpp.
References myDict.
Referenced by NLHandler::addConnection(), NLHandler::addLane(), MSRouteHandler::addStop(), MSVehicle::addStop(), getEdge(), NLTriggerBuilder::getLane(), NLDetectorBuilder::getLaneChecking(), NLShapeHandler::getLanePos(), getOpposite(), TraCIServerAPI_Lane::getShape(), MSPedestrianPushButton::loadPushButtons(), MSTriggeredRerouter::myStartElement(), NLTriggerBuilder::parseAndBuildLaneSpeedTrigger(), NLHandler::parseLanes(), TraCIServerAPI_Lane::processGet(), TraCIServerAPI_Vehicle::processSet(), and TraCIServerAPI_Lane::processSet().
|
static |
Returns the MSLane associated to the key id.
The lane is returned if exists, otherwise 0 is returned.
[in] | id | The id of the lane |
Definition at line 1298 of file MSLane.cpp.
References myDict.
|
inlinestatic |
Returns the number of stored lanes.
Definition at line 614 of file MSLane.h.
References enteredByLaneChange(), fill(), getFirstAnyVehicle(), getFirstFullVehicle(), getLastAnyVehicle(), getLastFullVehicle(), getParallelLane(), insertIDs(), isEmpty(), isInternal(), isLinkEnd(), leftByLaneChange(), myDict, removeVehicle(), resetPermissions(), setPermissions(), and succLinkSec().
|
inline |
Returns true if there is not a single vehicle on the lane.
Definition at line 553 of file MSLane.h.
References myVehBuffer, myVehicles, setLength(), setMaxSpeed(), and SUMOReal.
Referenced by MSQueueExport::writeLane().
void MSLane::enteredByLaneChange | ( | MSVehicle * | v | ) |
Definition at line 2023 of file MSLane.cpp.
References MSVehicleType::getLength(), MSVehicleType::getLengthWithGap(), MSBaseVehicle::getVehicleType(), myBruttoVehicleLengthSum, and myNettoVehicleLengthSum.
Referenced by dictSize(), and MSAbstractLaneChangeModel::primaryLaneChanged().
|
virtual |
Executes planned vehicle movements with regards to right-of-way.
This method goes through all vehicles calling their executeMove method which causes vehicles to update their positions and speeds. Vehicles wich move to the next lane are stored in the targets lane buffer
Reimplemented in GUILane.
Definition at line 1187 of file MSLane.cpp.
References MSVehicleTransfer::add(), appropriate(), MSVehicle::executeMove(), MSVehicle::getBestLanesContinuation(), getEdge(), Named::getID(), MSBaseVehicle::getID(), MSVehicle::getInfluencer(), MSVehicleTransfer::getInstance(), MSNet::getInstance(), MSVehicle::getLane(), MSVehicleType::getLength(), getLength(), MSVehicleType::getLengthWithGap(), MSVehicle::getPositionOnLane(), getSpeedLimit(), MSNet::getVehicleControl(), MSBaseVehicle::getVehicleType(), MSVehicle::getWaitingTime(), MSGlobals::gLateralResolution, MSGlobals::gTimeToGridlock, MSGlobals::gTimeToGridlockHighways, MSVehicle::hasArrived(), MSVehicle::hasInfluencer(), MSVehicle::isParking(), MSVehicle::isStopped(), MSEdge::isVaporizing(), MSVehicle::Influencer::isVTDControlled(), myBruttoVehicleLengthSum, myLinks, myNettoVehicleLengthSum, myVehBuffer, myVehicles, MSMoveReminder::NOTIFICATION_ARRIVED, MSMoveReminder::NOTIFICATION_VAPORIZED, MSVehicle::onRemovalFromNet(), MSVehicleControl::registerCollision(), MSVehicleControl::registerTeleportJam(), MSVehicleControl::registerTeleportWrongLane(), MSVehicleControl::registerTeleportYield(), MSVehicleControl::scheduleVehicleRemoval(), succLinkSec(), SUMOReal, time2string(), and WRITE_WARNING.
Referenced by GUILane::executeMovements(), and getIndex().
|
static |
Fills the given RTree with lane instances.
Definition at line 1326 of file MSLane.cpp.
References PositionVector::getBoxBoundary(), getShape(), Boundary::grow(), LANE_RTREE_QUAL, myDict, Boundary::xmax(), Boundary::xmin(), Boundary::ymax(), and Boundary::ymin().
Referenced by TraCIServer::collectObjectsInRange(), dictSize(), and MSNet::getLanesRTree().
void MSLane::forceVehicleInsertion | ( | MSVehicle * | veh, |
SUMOReal | pos, | ||
MSMoveReminder::Notification | notification, | ||
SUMOReal | posLat = 0 |
||
) |
Inserts the given vehicle at the given position.
No checks are done, vehicle insertion using this method may generate collisions (possibly delayed).
[in] | veh | The vehicle to insert |
[in] | pos | The position at which the vehicle shall be inserted |
[in] | notification | The cause of insertion (i.e. departure, teleport, parking) defaults to departure |
[in] | posLat | The lateral position at which the vehicle shall be inserted |
Definition at line 806 of file MSLane.cpp.
References getDepartSpeed(), MSVehicle::getSpeed(), MSBaseVehicle::hasDeparted(), incorporateVehicle(), myVehicles, SUMOReal, and MSVehicle::updateBestLanes().
Referenced by MSLaneChanger::changeOpposite(), getMoveReminders(), MSVehicle::Influencer::postProcessVTD(), and TraCIServerAPI_Vehicle::processSet().
bool MSLane::freeInsertion | ( | MSVehicle & | veh, |
SUMOReal | speed, | ||
MSMoveReminder::Notification | notification = MSMoveReminder::NOTIFICATION_DEPARTED |
||
) |
Tries to insert the given vehicle on any place.
[in] | veh | The vehicle to insert |
[in] | speed | The maximum insertion speed |
[in] | notification | The cause of insertion (i.e. departure, teleport, parking) defaults to departure |
Definition at line 284 of file MSLane.cpp.
References MSVehicle::getBackPositionOnLane(), MSVehicle::getCarFollowModel(), getFirstFullVehicle(), MSVehicleType::getLength(), getLength(), MSCFModel::getMaxDecel(), MSVehicleType::getMinGap(), getMissingRearGap(), MSVehicle::getPositionOnLane(), MSCFModel::getSecureGap(), MSVehicle::getSpeed(), MSBaseVehicle::getVehicleType(), MSCFModel::insertionFollowSpeed(), isInsertionSuccess(), MIN2(), myLength, myPartialVehicles, myVehicles, MSMoveReminder::NOTIFICATION_TELEPORT, POSITION_EPS, and SUMOReal.
Referenced by MSVehicleTransfer::checkInsertions(), getMoveReminders(), and insertVehicle().
|
inline |
Definition at line 444 of file MSLane.h.
References interpolateLanePosToGeometryPos(), myShape, and PositionVector::positionAtOffset().
Referenced by GUIE3Collector::MyWrapper::buildDefinition(), MSVehicle::computeAngle(), GUIVehicle::drawAction_drawRailCarriages(), GUIEdge::drawMesoVehicles(), GUIBaseVehicle::drawOnPos(), MSVehicle::getBackPosition(), NLShapeHandler::getLanePos(), MEVehicle::getPosition(), MSVehicle::getPosition(), GUIMEInductLoop::MyWrapper::MyWrapper(), GUIInstantInductLoop::MyWrapper::MyWrapper(), and GUIInductLoop::MyWrapper::MyWrapper().
SUMOReal MSLane::getBruttoOccupancy | ( | ) | const |
Returns the brutto (including minGaps) occupancy of this lane during the last step.
Definition at line 2041 of file MSLane.cpp.
References MSVehicleType::getLength(), MSVehicle::getPositionOnLane(), getVehiclesSecure(), MSBaseVehicle::getVehicleType(), myBruttoVehicleLengthSum, myLength, myPartialVehicles, myVehicles, releaseVehicles(), and SUMOReal.
Referenced by MSLCM_LC2013::_wantsChange(), GUILane::getColorValue(), getIncomingLanes(), GUILane::getParameterWindow(), GUILane::getScaleValue(), and MSEdge::insertVehicle().
|
inline |
Returns the sum of lengths of vehicles, including their minGaps, which were on the lane during the last step.
Definition at line 839 of file MSLane.h.
References getCO2Emissions(), getCOEmissions(), getElectricityConsumption(), getFuelConsumption(), getHarmonoise_NoiseEmissions(), getHCEmissions(), getNOxEmissions(), getPMxEmissions(), myBruttoVehicleLengthSum, and SUMOReal.
Referenced by MSVehicle::checkRewindLinkLanes().
|
inline |
Definition at line 905 of file MSLane.h.
References getFollower(), getOpposite(), getOppositeFollower(), getOppositeLeader(), getOppositePos(), loadState(), myRightSideOnEdge, myWidth, saveState(), sortPartialVehicles(), and SUMOReal.
Referenced by MSVehicle::getCenterOnEdge(), and MSAbstractLaneChangeModel::startLaneChangeManeuver().
SUMOReal MSLane::getCO2Emissions | ( | ) | const |
Returns the sum of last step CO2 emissions.
Definition at line 2100 of file MSLane.cpp.
References getVehiclesSecure(), releaseVehicles(), and SUMOReal.
Referenced by getBruttoVehLenSum(), GUILane::getColorValue(), GUILane::getScaleValue(), TraCIServerAPI_Lane::processGet(), and MSFullExport::writeLane().
SUMOReal MSLane::getCOEmissions | ( | ) | const |
Returns the sum of last step CO emissions.
Definition at line 2112 of file MSLane.cpp.
References getVehiclesSecure(), releaseVehicles(), and SUMOReal.
Referenced by getBruttoVehLenSum(), GUILane::getColorValue(), GUILane::getScaleValue(), TraCIServerAPI_Lane::processGet(), and MSFullExport::writeLane().
std::pair< MSVehicle *const, SUMOReal > MSLane::getCriticalLeader | ( | SUMOReal | dist, |
SUMOReal | seen, | ||
SUMOReal | speed, | ||
const MSVehicle & | veh | ||
) | const |
Returns the most dangerous leader and the distance to him.
Goes along the vehicle's estimated used lanes (bestLaneConts). For each link, it is determined whether the ego vehicle will pass it. If so, the subsequent lane is investigated. Check all lanes up to the stopping distance of ego. Return the leader vehicle (and the gap) which puts the biggest speed constraint on ego.
If no leading vehicle was found, <0, -1> is returned.
Pretty slow, as it has to go along lanes.
[in] | dist | The distance to investigate |
[in] | seen | The already seen place (normally the place in front on own lane) |
[in] | speed | The speed of the vehicle used for determining whether a subsequent link will be opened at arrival time |
[in] | veh | The (ego) vehicle for which the information shall be computed |
Definition at line 1885 of file MSLane.cpp.
References MSCFModel::brakeGap(), MSVehicle::getBackPositionOnLane(), MSVehicle::getBestLanesContinuation(), MSVehicle::getCarFollowModel(), MSNet::getCurrentTimeStep(), MSBaseVehicle::getImpatience(), MSNet::getInstance(), getLastAnyVehicle(), MSVehicle::getLateralPositionOnLane(), MSVehicleType::getLength(), getLength(), MSCFModel::getMaxDecel(), MSVehicleType::getMinGap(), MSVehicle::getSafeFollowSpeed(), MSVehicle::getSpeed(), getVehicleMaxSpeed(), MSBaseVehicle::getVehicleType(), MSCFModel::insertionFollowSpeed(), isLinkEnd(), max, MAX2(), NUMERICAL_EPS, succLinkSec(), SUMOReal, and TIME2STEPS.
Referenced by MSLaneChanger::checkChange(), and getIncomingLanes().
int MSLane::getCrossingIndex | ( | ) | const |
return the index of the link to the next crossing if this is walkingArea, else -1
Definition at line 2030 of file MSLane.cpp.
References myLinks, and SUMOReal.
Referenced by getIndex().
Definition at line 372 of file MSLane.cpp.
References DEPART_SPEED_DEFAULT, DEPART_SPEED_GIVEN, DEPART_SPEED_MAX, DEPART_SPEED_RANDOM, SUMOVehicleParameter::departSpeed, SUMOVehicleParameter::departSpeedProcedure, MSBaseVehicle::getParameter(), getVehicleMaxSpeed(), RandHelper::rand(), and SUMOReal.
Referenced by forceVehicleInsertion(), and insertVehicle().
|
inline |
Returns the lane's edge.
Definition at line 571 of file MSLane.h.
References clear(), dictionary(), getInternalFollower(), and myEdge.
Referenced by MSLCM_LC2013::_patchSpeed(), MSLCM_LC2013::_wantsChange(), MSLCM_SL2015::_wantsChangeSublane(), TraCIServerAPI_Lane::StoringVisitor::add(), addApproachingLane(), MSRouteHandler::addStop(), MSVehicle::addStop(), MSEdge::allowedLanes(), MSSwarmTrafficLightLogic::allowLine(), MSSOTLE2Sensors::buildSensorForLane(), MSEdge::changeLanes(), MSLaneChanger::changeOpposite(), MSLCM_SL2015::checkBlocking(), MSLaneChanger::checkChange(), MSVehicle::checkRewindLinkLanes(), MSEdge::closeBuilding(), GUILane::closeTraffic(), MSDevice_Tripinfo::computeLengthAndDuration(), GUIDetectorBuilder::createInductLoop(), NLDetectorBuilder::createInductLoop(), MSLCM_LC2013::distanceAlongNextRoundabout(), GUILane::drawLinkNo(), GUILane::drawLinkRules(), GUILane::drawTLSLinkNo(), MSVehicle::enterLaneAtMove(), MSVehicle::executeMove(), executeMovements(), MS_E2_ZS_CollectorOverLanes::extendTo(), MSVehicle::getBestLanesContinuation(), MSVehicle::getCenterOnEdge(), MSVehicle::getDistanceToPosition(), getFollowersOnConsecutive(), MSLink::getInternalLengthsAfter(), MSVehicle::getLaneIndex(), MS_E2_ZS_CollectorOverLanes::getLanePredeccessorLanes(), MSVehicle::getLatOffset(), getLogicalPredecessorLane(), MSPModel_Striping::PState::getNextEdge(), MSPModel_Striping::getNextLane(), MSPModel_Striping::getNextLaneObstacles(), MSVehicle::getPosition(), MSLCM_LC2013::getRoundaboutAheadInfo(), MSAbstractLaneChangeModel::getShadowDirection(), MSStoppingPlace::hasAccess(), MSVehicle::Influencer::implicitDeltaPosVTD(), MSVehicle::Influencer::implicitSpeedVTD(), MSVehicle::influenceChangeDecision(), MSRailSignal::init(), isInsertionSuccess(), MSJunction::isLeader(), MSLCM_SL2015::keepLatGap(), MSLink::lastWasContMajor(), MESegment::limitedControlOverride(), MSPedestrianPushButton::loadPushButtons(), MSPModel_Striping::moveInDirection(), MSPModel_Striping::moveInDirectionOnLane(), MSPModel_Striping::PState::moveToNextLane(), GUIViewTraffic::onCmdAddRerouter(), GUIViewTraffic::onCmdCloseEdge(), MSLane::edge_finder::operator()(), NLTriggerBuilder::parseAndBuildCalibrator(), MSRouteHandler::parseWalkPositions(), MSLCM_DK2008::patchSpeed(), MSVehicle::planMoveInternal(), MSLCM_SL2015::prepareStep(), MSContainer::MSContainerStage_Driving::proceed(), MSPerson::MSPersonStage_Driving::proceed(), TraCIServerAPI_Vehicle::processGet(), TraCIServerAPI_Lane::processGet(), MSVehicle::processNextStop(), TraCIServerAPI_Vehicle::processSet(), TraCIServerAPI_Lane::processSet(), MSPModel_Striping::PState::PState(), MSVehicle::replaceRoute(), MSVehicle::resumeFromStopping(), MSLink::setRequestInformation(), MSAbstractLaneChangeModel::startLaneChangeManeuver(), MSVehicle::unsafeLinkAhead(), MSVehicle::updateBestLanes(), MSLCM_SL2015::updateExpectedSublaneSpeeds(), TraCIServerAPI_Vehicle::vtdMap(), MSLCM_DK2008::wantsChangeToLeft(), MSLCM_DK2008::wantsChangeToRight(), and MSFCDExport::write().
SUMOReal MSLane::getElectricityConsumption | ( | ) | const |
Returns the sum of last step electricity consumption.
Definition at line 2172 of file MSLane.cpp.
References getVehiclesSecure(), releaseVehicles(), and SUMOReal.
Referenced by getBruttoVehLenSum(), GUILane::getColorValue(), GUILane::getScaleValue(), TraCIServerAPI_Lane::processGet(), and MSFullExport::writeLane().
MSVehicle * MSLane::getFirstAnyVehicle | ( | ) | const |
returns the first vehicle that is fully or partially on this lane
Definition at line 1447 of file MSLane.cpp.
References MSVehicle::getPositionOnLane(), myPartialVehicles, and myVehicles.
Referenced by dictSize(), and getFollowerOnConsecutive().
MSVehicle * MSLane::getFirstFullVehicle | ( | ) | const |
returns the first vehicle for which this lane is responsible or 0
Definition at line 1424 of file MSLane.cpp.
References myVehicles.
Referenced by dictSize(), freeInsertion(), and getFollowerOnConsecutive().
const MSLeaderInfo & MSLane::getFirstVehicleInformation | ( | const MSVehicle * | ego, |
SUMOReal | latOffset, | ||
bool | onlyFrontOnLane, | ||
SUMOReal | maxPos = std::numeric_limits<SUMOReal>::max() , |
||
bool | allowCached = true |
||
) | const |
analogue to getLastVehicleInformation but in the upstream direction
Definition at line 885 of file MSLane.cpp.
References MSLeaderInfo::addLeader(), anyVehiclesUpstreamBegin(), DEBUG_COND2, MSNet::getCurrentTimeStep(), MSBaseVehicle::getID(), MSNet::getInstance(), MSVehicle::getLatOffset(), MSVehicle::getPositionOnLane(), MSVehicle::isFrontOnLane(), max, myFollowerInfo, myFollowerInfoTime, myLeaderInfoTmp, and SUMOReal.
Referenced by getFollowersOnConsecutive(), and getMoveReminders().
std::pair< MSVehicle *const, SUMOReal > MSLane::getFollower | ( | const MSVehicle * | ego, |
SUMOReal | egoPos, | ||
SUMOReal | dist | ||
) | const |
Find follower vehicle for the given ego vehicle (which may be on the opposite direction lane)
[in] | ego | The ego vehicle |
[in] | egoPos | The ego position mapped to the current lane |
[in] | dist | The look-back distance when looking at consecutive lanes |
Definition at line 2521 of file MSLane.cpp.
References anyVehiclesUpstreamBegin(), anyVehiclesUpstreamEnd(), DEBUG_COND2, MSVehicle::getCarFollowModel(), getFollowerOnConsecutive(), Named::getID(), MSBaseVehicle::getID(), MSVehicleType::getLength(), MSCFModel::getMaxDecel(), MSVehicle::getPositionOnLane(), MSVehicle::getSpeed(), and MSBaseVehicle::getVehicleType().
Referenced by getCenterOnEdge(), getOppositeFollower(), and getOppositeLeader().
std::pair< MSVehicle *const, SUMOReal > MSLane::getFollowerOnConsecutive | ( | SUMOReal | backOffset, |
SUMOReal | leaderSpeed, | ||
SUMOReal | leaderMaxDecel, | ||
SUMOReal | dist = -1 |
||
) | const |
return the follower with the largest missing rear gap among all predecessor lanes (within dist)
XXX dubious term. here for backwards compatibility
Definition at line 1640 of file MSLane.cpp.
References DEBUG_COND, getFirstAnyVehicle(), getFirstFullVehicle(), Named::getID(), Named::getIDSecure(), getIncomingLanes(), getLength(), getMaximumBrakeDist(), MSVehicle::getPositionOnLane(), MSLane::IncomingLaneInfo::lane, MSLane::IncomingLaneInfo::length, max, MAX2(), myIncomingLanes, SIMTIME, SUMOReal, and MSLane::IncomingLaneInfo::viaLink.
Referenced by getFollower(), getIncomingLanes(), and getMissingRearGap().
MSLeaderDistanceInfo MSLane::getFollowersOnConsecutive | ( | const MSVehicle * | ego, |
bool | allSublanes | ||
) | const |
return the sublane followers with the largest missing rear gap among all predecessor lanes (within dist)
XXX iterate in reverse and abort when there are no more freeSublanes
XXX dubious term. here for backwards compatibility
Definition at line 2268 of file MSLane.cpp.
References MSCriticalFollowerDistanceInfo::addFollower(), anyVehiclesBegin(), anyVehiclesEnd(), DEBUG_COND2, getEdge(), getFirstVehicleInformation(), Named::getID(), MSBaseVehicle::getID(), Named::getIDSecure(), getIncomingLanes(), MSVehicle::getLane(), MSVehicle::getLatOffset(), getLength(), getMaximumBrakeDist(), MSVehicleType::getMinGap(), MSVehicle::getPositionOnLane(), getRightSideOnEdge(), MSBaseVehicle::getVehicleType(), MSVehicle::isFrontOnLane(), MSLane::IncomingLaneInfo::lane, MSLane::IncomingLaneInfo::length, MAX2(), myIncomingLanes, MSLeaderInfo::numFreeSublanes(), SIMTIME, SUMOReal, MSLeaderInfo::toString(), MSCriticalFollowerDistanceInfo::toString(), and MSLane::IncomingLaneInfo::viaLink.
Referenced by getIncomingLanes(), and isInsertionSuccess().
SUMOReal MSLane::getFuelConsumption | ( | ) | const |
Returns the sum of last step fuel consumption.
Definition at line 2160 of file MSLane.cpp.
References getVehiclesSecure(), releaseVehicles(), and SUMOReal.
Referenced by getBruttoVehLenSum(), GUILane::getColorValue(), GUILane::getScaleValue(), TraCIServerAPI_Lane::processGet(), and MSFullExport::writeLane().
SUMOReal MSLane::getHarmonoise_NoiseEmissions | ( | ) | const |
Returns the sum of last step noise emissions.
Definition at line 2184 of file MSLane.cpp.
References getVehiclesSecure(), releaseVehicles(), HelpersHarmonoise::sum(), and SUMOReal.
Referenced by getBruttoVehLenSum(), GUILane::getColorValue(), GUILane::getScaleValue(), TraCIServerAPI_Lane::processGet(), and MSFullExport::writeLane().
SUMOReal MSLane::getHCEmissions | ( | ) | const |
Returns the sum of last step HC emissions.
Definition at line 2148 of file MSLane.cpp.
References getVehiclesSecure(), releaseVehicles(), and SUMOReal.
Referenced by getBruttoVehLenSum(), GUILane::getColorValue(), GUILane::getScaleValue(), TraCIServerAPI_Lane::processGet(), and MSFullExport::writeLane().
|
inlineinherited |
Returns the 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(), 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(), 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(), getFollower(), getFollowerOnConsecutive(), getFollowersOnConsecutive(), GNEEdge::getGNEJunctionDest(), GNEEdge::getGNEJunctionSource(), MSLink::getInternalLengthsAfter(), MS_E2_ZS_CollectorOverLanes::getLanePredeccessorLanes(), getLastVehicleInformation(), MSVehicle::getLatOffset(), getLeader(), getLeaderOnConsecutive(), getLeadersOnConsecutive(), MSTLLogicControl::TLSLogicVariants::getLogicInstantiatingOff(), MSDeterministicHiLevelTrafficLightLogic::getMeanSpeedForInputLanes(), MSDeterministicHiLevelTrafficLightLogic::getMeanSpeedForOutputLanes(), NIImporter_VISUM::getNamedEdgeContinuating(), MSPerson::getNextEdge(), MSPModel_Striping::getNextLane(), getOppositeFollower(), getOppositeLeader(), getOppositePos(), GUIInstantInductLoop::MyWrapper::getParameterWindow(), GUIMEInductLoop::MyWrapper::getParameterWindow(), GUIVehicle::getParameterWindow(), GUI_E2_ZS_Collector::MyWrapper::getParameterWindow(), GUIInductLoop::MyWrapper::getParameterWindow(), 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(), 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(), 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(), 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(), resetPartialOccupation(), NBEdge::restoreRestrictedLane(), GNEEdge::retrieveConnection(), NIXMLTrafficLightsHandler::retrieveLaneIndex(), RODFNet::revalidateFlows(), RONet::saveAndRemoveRoutesUntil(), MSBaseVehicle::saveState(), 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(), 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(), 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().
|
inlinestaticinherited |
get an identifier for Named-like object which may be Null
Definition at line 59 of file Named.h.
Referenced by MSLCM_LC2013::_wantsChange(), MSLCM_SL2015::_wantsChangeSublane(), MSLaneChanger::changeOpposite(), MSLaneChanger::continueChange(), MSVehicle::getBackPositionOnLane(), MSVehicle::getCenterOnEdge(), getFollowerOnConsecutive(), getFollowersOnConsecutive(), MSVehicle::getLatOffset(), operator<<(), MSLCM_SL2015::saveBlockerLength(), MSLCM_LC2013::saveBlockerLength(), MSLCM_LC2013::slowDownForBlocked(), MSLCM_SL2015::slowDownForBlocked(), MSLaneChangerSublane::startChangeSublane(), MSLeaderInfo::toString(), MSLeaderDistanceInfo::toString(), toString(), MSCriticalFollowerDistanceInfo::toString(), MSVehicle::updateBestLanes(), and MSAbstractLaneChangeModel::updateShadowLane().
|
inline |
Definition at line 708 of file MSLane.h.
References addApproachingLane(), getBruttoOccupancy(), getCriticalLeader(), getFollowerOnConsecutive(), getFollowersOnConsecutive(), getIncomingLinkState(), getLeader(), getLeaderOnConsecutive(), getLeadersOnConsecutive(), getLogicalPredecessorLane(), getMeanSpeed(), getMissingRearGap(), getNettoOccupancy(), getOutgoingLanes(), getPartialBehind(), getWaitingSeconds(), isApproachedFrom(), myIncomingLanes, and SUMOReal.
Referenced by MSLink::getApproachingLane(), getFollowerOnConsecutive(), getFollowersOnConsecutive(), MSPModel_Striping::getNextWalkingArea(), MSRailSignal::init(), and MSLink::setRequestInformation().
LinkState MSLane::getIncomingLinkState | ( | ) | const |
get the state of the link from the logical predecessor to this lane
Definition at line 1994 of file MSLane.cpp.
References MSLinkContHelper::getConnectingLink(), getLogicalPredecessorLane(), MSLink::getState(), and LINKSTATE_DEADEND.
Referenced by getIncomingLanes().
|
inline |
Returns the lane's index.
Definition at line 503 of file MSLane.h.
References appropriate(), detectCollisions(), executeMovements(), getCrossingIndex(), getLinkCont(), integrateNewVehicle(), myIndex, and planMovements().
Referenced by MSLCM_SL2015::_wantsChangeSublane(), GUILane::drawLinkNo(), MSAbstractLaneChangeModel::getShadowDirection(), MSLink::getZipperSpeed(), MSLink::opened(), MSLaneChangerSublane::startChangeSublane(), and MSLaneChangerSublane::updateChanger().
const MSEdge * MSLane::getInternalFollower | ( | ) | const |
Returns the lane's follower if it is an internal lane, the edge of the lane otherwise.
Definition at line 1275 of file MSLane.cpp.
References MSEdge::EDGEFUNCTION_INTERNAL, MSEdge::getPurpose(), MSEdge::getSuccessors(), and myEdge.
Referenced by getEdge(), MSVehicle::getRerouteOrigin(), and MSVehicle::updateBestLanes().
MSVehicle * MSLane::getLastAnyVehicle | ( | ) | const |
returns the last vehicle that is fully or partially on this lane
Definition at line 1433 of file MSLane.cpp.
References myPartialVehicles, and myVehicles.
Referenced by MSVehicle::checkRewindLinkLanes(), dictSize(), getCriticalLeader(), isInsertionSuccess(), and MSLink::maybeOccupied().
MSVehicle * MSLane::getLastFullVehicle | ( | ) | const |
returns the last vehicle for which this lane is responsible or 0
Definition at line 1415 of file MSLane.cpp.
References myVehicles.
Referenced by dictSize().
const MSLeaderInfo & MSLane::getLastVehicleInformation | ( | const MSVehicle * | ego, |
SUMOReal | latOffset, | ||
SUMOReal | minPos = 0 , |
||
bool | allowCached = true |
||
) | const |
Returns the last vehicles on the lane.
The information about the last vehicles in this lanes in all sublanes occupied by ego are returned. Partial occupators are included
[in] | ego | The vehicle for which to restrict the returned leaderInfo |
[in] | minPos | The minimum position from which to start search for leaders |
[in] | allowCached | Whether the cached value may be used |
Definition at line 834 of file MSLane.cpp.
References MSLeaderInfo::addLeader(), anyVehiclesBegin(), DEBUG_COND2, MSNet::getCurrentTimeStep(), Named::getID(), MSBaseVehicle::getID(), MSNet::getInstance(), MSVehicle::getLatOffset(), MSVehicle::getPositionOnLane(), myLeaderInfo, myLeaderInfoTime, myLeaderInfoTmp, SUMOReal, and MSLeaderInfo::toString().
Referenced by detectCollisions(), getLeadersOnConsecutive(), getMoveReminders(), isInsertionSuccess(), and MSVehicle::planMoveInternal().
std::pair< MSVehicle *const, SUMOReal > MSLane::getLeader | ( | const MSVehicle * | veh, |
const SUMOReal | vehPos, | ||
const std::vector< MSLane *> & | bestLaneConts, | ||
SUMOReal | dist = -1 , |
||
bool | checkTmpVehicles = false |
||
) | const |
Returns the immediate leader of veh and the distance to veh starting on this lane.
Iterates over the current lane to find a leader and then uses getLeaderOnConsecutive()
[in] | veh | The vehicle for which the information shall be computed |
[in] | vehPos | The vehicle position relative to this lane (may be negative) |
[in] | bestLaneConts | The succeding lanes that shall be checked (if any) |
[in] | dist | Optional distance to override default (ego stopDist) |
[in] | checkTmpVehicles | Whether myTmpVehicles should be used instead of myVehicles |
Definition at line 1735 of file MSLane.cpp.
References anyVehiclesBegin(), anyVehiclesEnd(), MSCFModel::brakeGap(), DEBUG_COND2, MSVehicle::getBackPositionOnLane(), MSVehicle::getCarFollowModel(), Named::getID(), MSBaseVehicle::getID(), getLeaderOnConsecutive(), getLength(), MSVehicleType::getMinGap(), MSVehicle::getPositionOnLane(), MSVehicle::getSpeed(), MSBaseVehicle::getVehicleType(), myTmpVehicles, myVehicles, NUMERICAL_EPS, SUMOReal, and toString().
Referenced by MSLaneChanger::checkChange(), getIncomingLanes(), getOppositeFollower(), and getOppositeLeader().
std::pair< MSVehicle *const, SUMOReal > MSLane::getLeaderOnConsecutive | ( | SUMOReal | dist, |
SUMOReal | seen, | ||
SUMOReal | speed, | ||
const MSVehicle & | veh, | ||
const std::vector< MSLane *> & | bestLaneConts | ||
) | const |
Returns the immediate leader and the distance to him.
Goes along the vehicle's estimated used lanes (bestLaneConts). For each link, it is determined whether the vehicle will pass it. If so, the subsequent lane is investigated. If a vehicle (leader) is found, it is returned, together with the length of the investigated lanes until this vehicle's end, including the already seen place (seen).
If no leading vehicle was found, <0, -1> is returned.
Pretty slow, as it has to go along lanes.
[in] | dist | The distance to investigate |
[in] | seen | The already seen place (normally the place in front on own lane) |
[in] | speed | The speed of the vehicle used for determining whether a subsequent link will be opened at arrival time |
[in] | veh | The vehicle for which the information shall be computed |
[in] | bestLaneConts | The lanes the vehicle will use in future |
Definition at line 1793 of file MSLane.cpp.
References MSCFModel::brakeGap(), DEBUG_COND2, MSVehicle::getBackPositionOnLane(), MSVehicle::getCarFollowModel(), MSNet::getCurrentTimeStep(), Named::getID(), MSBaseVehicle::getID(), MSBaseVehicle::getImpatience(), MSNet::getInstance(), MSVehicle::getLateralPositionOnLane(), MSVehicleType::getLength(), getLength(), MSCFModel::getMaxDecel(), MSVehicleType::getMinGap(), MSBaseVehicle::getVehicleType(), MAX2(), myPartialVehicles, NUMERICAL_EPS, succLinkSec(), SUMOReal, TIME2STEPS, and toString().
Referenced by getIncomingLanes(), getLeader(), and MSVehicle::getLeader().
void MSLane::getLeadersOnConsecutive | ( | SUMOReal | dist, |
SUMOReal | seen, | ||
SUMOReal | speed, | ||
const MSVehicle * | ego, | ||
const std::vector< MSLane *> & | bestLaneConts, | ||
MSLeaderDistanceInfo & | result | ||
) | const |
Returns the immediate leaders and the distance to them (as getLeaderOnConsecutive but for the sublane case)
Definition at line 2385 of file MSLane.cpp.
References MSLeaderDistanceInfo::addLeader(), MSCFModel::brakeGap(), DEBUG_COND2, MSVehicle::getBackPositionOnLane(), MSVehicle::getCarFollowModel(), MSNet::getCurrentTimeStep(), Named::getID(), MSBaseVehicle::getID(), MSBaseVehicle::getImpatience(), MSNet::getInstance(), getLastVehicleInformation(), MSVehicle::getLateralPositionOnLane(), MSVehicleType::getLength(), getLength(), MSCFModel::getMaxDecel(), MSVehicleType::getMinGap(), getVehicleMaxSpeed(), MSBaseVehicle::getVehicleType(), MSVehicle::isFrontOnLane(), isLinkEnd(), MAX2(), MIN2(), myPartialVehicles, NUMERICAL_EPS, MSLeaderInfo::numFreeSublanes(), MSLeaderInfo::numSublanes(), SIMTIME, succLinkSec(), TIME2STEPS, MSLeaderInfo::toString(), and MSLink::LinkLeader::vehAndGap.
Referenced by getIncomingLanes().
|
inline |
Returns the lane's length.
Definition at line 480 of file MSLane.h.
References myLength.
Referenced by MSLCM_LC2013::_wantsChange(), MSVehicle::adaptLaneEntering2MoveReminder(), MSVehicle::adaptToLeaders(), NLTriggerBuilder::addAccess(), NLHandler::addConnection(), addIncomingLane(), MSVehicle::addStop(), GUI_E2_ZS_CollectorOverLanes::buildCollector(), MS_E2_ZS_CollectorOverLanes::buildCollector(), MSSOTLE2Sensors::buildContinueSensior(), MSSOTLE2Sensors::buildCountSensorForLane(), MSSOTLE2Sensors::buildCountSensorForOutLane(), MSSOTLE2Sensors::buildSensorForLane(), MSSOTLE2Sensors::buildSensorForOutLane(), MSLaneChanger::changeOpposite(), MSLaneChanger::checkChange(), MSVehicle::checkRewindLinkLanes(), NLDetectorBuilder::convUncontE2PosLength(), MSLCM_LC2013::distanceAlongNextRoundabout(), MSPModel_Striping::PState::distToLaneEnd(), GUIVehicle::drawAction_drawRailCarriages(), MSVehicle::executeMove(), executeMovements(), MS_E2_ZS_CollectorOverLanes::extendTo(), freeInsertion(), GUILane::getColorValue(), getCriticalLeader(), MSVehicle::getDistanceToPosition(), MSE2Collector::getEstimatedCurrentVehicleNumber(), MSE2Collector::getEstimateQueueLength(), getFollowerOnConsecutive(), getFollowersOnConsecutive(), MSLink::getInternalLengthsAfter(), TraCIServerAPI_Simulation::getLaneChecking(), NLShapeHandler::getLanePos(), getLeader(), MSVehicle::getLeader(), getLeaderOnConsecutive(), MSLaneChangerSublane::getLeaders(), getLeadersOnConsecutive(), getOppositePos(), NLTriggerBuilder::getPosition(), NLDetectorBuilder::getPositionChecking(), MSDevice_Battery::getPropEnergy(), MSVehicle::getRerouteOrigin(), MSLCM_LC2013::getRoundaboutAheadInfo(), MSVehicle::getSafeFollowSpeed(), MSVehicle::getSpaceTillLastStanding(), MSActuatedTrafficLightLogic::init(), MS_E2_ZS_CollectorOverLanes::init(), insertVehicle(), isInsertionSuccess(), MSLink::maybeOccupied(), MSPModel_Striping::moveInDirectionOnLane(), MSPModel_Striping::PState::moveToNextLane(), NLTriggerBuilder::parseAndBuildChargingStation(), NLTriggerBuilder::parseAndBuildStoppingPlace(), MSVehicle::planMoveInternal(), MSVehicle::Influencer::postProcessVTD(), TraCIServerAPI_Vehicle::processGet(), TraCIServerAPI_Lane::processGet(), GUIVehicle::selectBlockingFoes(), MSVehicle::setBlinkerInformation(), MSLink::setRequestInformation(), MSVehicle::unsafeLinkAhead(), MSVehicle::updateBestLanes(), TraCIServerAPI_Vehicle::vtdMap(), MSLCM_DK2008::wantsChangeToLeft(), MSLCM_DK2008::wantsChangeToRight(), MSMeanData::writeEdge(), and MSQueueExport::writeLane().
|
inline |
return shape.length() / myLength
Definition at line 432 of file MSLane.h.
References myLengthGeometryFactor.
const MSLinkCont & MSLane::getLinkCont | ( | ) | const |
returns the container with all links !!!
Definition at line 1512 of file MSLane.cpp.
References myLinks.
Referenced by MSLCM_LC2013::_wantsChange(), MSLCM_SL2015::_wantsChangeSublane(), MSEdge::changeLanes(), MSLCM_SL2015::computeSublaneShift(), MSLCM_LC2013::distanceAlongNextRoundabout(), MSLink::getApproachingLane(), MSVehicle::getBestLanesContinuation(), MSLinkContHelper::getConnectingLink(), getIndex(), MSLink::getInternalLengthsAfter(), MESegment::getLink(), MSPModel_Striping::getNextLane(), MSPModel_Striping::getNextWalkingArea(), MSRailSignal::init(), MSRightOfWayJunction::postloadInit(), TraCIServerAPI_Lane::processGet(), MSEdge::recalcCache(), MSVehicle::setBlinkerInformation(), MSLink::setRequestInformation(), MSVehicle::updateBestLanes(), MSLCM_DK2008::wantsChangeToLeft(), and MSLCM_DK2008::wantsChangeToRight().
MSLane * MSLane::getLogicalPredecessorLane | ( | ) | const |
get the most likely precedecessor lane (sorted using by_connections_to_sorter). The result is cached in myLogicalPredecessorLane
Definition at line 1954 of file MSLane.cpp.
References getEdge(), MSEdge::getIncomingEdges(), myEdge, myIncomingLanes, and myLogicalPredecessorLane.
Referenced by MSEdge::allowsLaneChanging(), MSEdge::changeLanes(), GUILane::drawGL(), GUILane::drawLinkNo(), GUILane::drawLinkRules(), GUILane::drawTLSLinkNo(), MSVehicle::enterLaneAtInsertion(), MSVehicle::enterLaneAtLaneChange(), getIncomingLanes(), getIncomingLinkState(), MSLink::getInternalLengthsAfter(), MSPModel_Striping::getNextLane(), MSLink::lastWasContMajor(), MSVehicle::planMoveInternal(), MSLink::setRequestInformation(), MSVehicle::updateBestLanes(), and TraCIServerAPI_Vehicle::vtdMap().
return the (first) predecessor lane from the given edge
Definition at line 1982 of file MSLane.cpp.
References getEdge(), and myIncomingLanes.
|
inlineinherited |
Returns the inner key/value map.
Definition at line 107 of file Parameterised.h.
References Parameterised::myMap.
Referenced by NBTrafficLightDefinition::compute(), MSDevice_Vehroutes::generateOutput(), GUIPerson::getParameterWindow(), GUIMEVehicle::getTypeParameterWindow(), GUIVehicle::getTypeParameterWindow(), TraCIServerAPI_TLS::processGet(), ROVehicle::saveAsXML(), ROPerson::saveAsXML(), SUMOVTypeParameter::write(), PointOfInterest::writeXML(), and SUMO::Polygon::writeXML().
|
protected |
compute maximum braking distance on this lane
Definition at line 1631 of file MSLane.cpp.
References MSNet::getInstance(), MSVehicleControl::getMaxSpeedFactor(), MSVehicleControl::getMinDeceleration(), getSpeedLimit(), MSNet::getVehicleControl(), and SUMOReal.
Referenced by getFollowerOnConsecutive(), and getFollowersOnConsecutive().
SUMOReal MSLane::getMeanSpeed | ( | ) | const |
Returns the mean speed on this lane.
Definition at line 2084 of file MSLane.cpp.
References getVehiclesSecure(), myMaxSpeed, myVehicles, releaseVehicles(), and SUMOReal.
Referenced by GUILane::getColorValue(), getIncomingLanes(), GUILane::getScaleValue(), TraCIServerAPI_Lane::processGet(), and MSFullExport::writeLane().
SUMOReal MSLane::getMissingRearGap | ( | SUMOReal | backOffset, |
SUMOReal | leaderSpeed, | ||
SUMOReal | leaderMaxDecel | ||
) | const |
return by how much further the leader must be inserted to avoid rear end collisions
Definition at line 1615 of file MSLane.cpp.
References MSVehicle::getCarFollowModel(), getFollowerOnConsecutive(), MSCFModel::getSecureGap(), MSVehicle::getSpeed(), and SUMOReal.
Referenced by freeInsertion(), getIncomingLanes(), and isInsertionSuccess().
|
inline |
Return the list of this lane's move reminders.
Definition at line 228 of file MSLane.h.
References checkFailure(), forceVehicleInsertion(), freeInsertion(), getFirstVehicleInformation(), getLastVehicleInformation(), insertVehicle(), isInsertionSuccess(), lastInsertion(), max, myMoveReminders, MSMoveReminder::NOTIFICATION_DEPARTED, resetPartialOccupation(), setPartialOccupation(), and SUMOReal.
Referenced by MSVehicle::adaptLaneEntering2MoveReminder(), MSVehicle::enterLaneAtInsertion(), and MSVehicle::enterLaneAtLaneChange().
SUMOReal MSLane::getNettoOccupancy | ( | ) | const |
Returns the netto (excluding minGaps) occupancy of this lane during the last step (including minGaps)
Definition at line 2056 of file MSLane.cpp.
References MSVehicleType::getLength(), MSVehicle::getPositionOnLane(), getVehiclesSecure(), MSBaseVehicle::getVehicleType(), myLength, myNettoVehicleLengthSum, myPartialVehicles, myVehicles, releaseVehicles(), and SUMOReal.
Referenced by GUILane::getColorValue(), getIncomingLanes(), GUILane::getParameterWindow(), GUILane::getScaleValue(), TraCIServerAPI_Lane::processGet(), and MSFullExport::writeLane().
SUMOReal MSLane::getNOxEmissions | ( | ) | const |
Returns the sum of last step NOx emissions.
Definition at line 2136 of file MSLane.cpp.
References getVehiclesSecure(), releaseVehicles(), and SUMOReal.
Referenced by getBruttoVehLenSum(), GUILane::getColorValue(), GUILane::getScaleValue(), TraCIServerAPI_Lane::processGet(), and MSFullExport::writeLane().
|
inline |
Returns this lane's numerical id.
Definition at line 419 of file MSLane.h.
References myNumericalID.
Referenced by MSPModel_Striping::lane_by_numid_sorter::operator()(), and MSPModel_Striping::walkingarea_path_sorter::operator()().
MSLane * MSLane::getOpposite | ( | ) | const |
return the opposite direction lane for lane changing or 0
Definition at line 2500 of file MSLane.cpp.
References dictionary(), myNeighs, and SUMOReal.
Referenced by MSLaneChanger::changeOpposite(), MSVehicle::executeMove(), getCenterOnEdge(), getOppositePos(), MSVehicle::planMoveInternal(), and MSVehicle::updateState().
Definition at line 2561 of file MSLane.cpp.
References DEBUG_COND2, MSVehicle::getBackPositionOnLane(), getFollower(), Named::getID(), MSBaseVehicle::getID(), MSVehicle::getLaneChangeModel(), getLeader(), MSVehicleType::getLength(), getOppositePos(), MSVehicle::getPositionOnLane(), MSBaseVehicle::getVehicleType(), MSAbstractLaneChangeModel::isOpposite(), and SIMTIME.
Referenced by MSLaneChanger::changeOpposite(), and getCenterOnEdge().
std::pair< MSVehicle *const, SUMOReal > MSLane::getOppositeLeader | ( | const MSVehicle * | ego, |
SUMOReal | dist | ||
) | const |
Definition at line 2540 of file MSLane.cpp.
References DEBUG_COND2, MSVehicle::getBestLanesContinuation(), getFollower(), Named::getID(), MSBaseVehicle::getID(), MSVehicle::getLaneChangeModel(), getLeader(), MSVehicleType::getLength(), MSVehicleType::getMinGap(), getOppositePos(), MSVehicle::getPositionOnLane(), MSBaseVehicle::getVehicleType(), MSAbstractLaneChangeModel::isOpposite(), SIMTIME, and SUMOReal.
Referenced by MSLaneChanger::changeOpposite(), and getCenterOnEdge().
return the corresponding position on the opposite lane
Definition at line 2509 of file MSLane.cpp.
References Named::getID(), getLength(), and getOpposite().
Referenced by MSLaneChanger::changeOpposite(), MSVehicle::executeMove(), getCenterOnEdge(), getOppositeFollower(), getOppositeLeader(), and MSVehicle::updateState().
std::vector< const MSLane * > MSLane::getOutgoingLanes | ( | ) | const |
get the list of outgoing lanes
Definition at line 2005 of file MSLane.cpp.
References myLinks.
Referenced by getIncomingLanes(), MSRailSignal::init(), and MSVehicle::replaceRoute().
MSLane * MSLane::getParallelLane | ( | int | offset | ) | const |
Returns the lane with the given offset parallel to this one or 0 if it does not exist.
[in] | offset | The offset of the result lane |
Definition at line 1561 of file MSLane.cpp.
References myEdge, and MSEdge::parallelLane().
Referenced by MSLaneChanger::checkChange(), MSLink::computeParallelLink(), dictSize(), MSAbstractLaneChangeModel::getShadowLane(), and MSVehicle::planMoveInternal().
|
inherited |
Returns the value for a given key.
[in] | key | The key to ask for |
[in] | defaultValue | The default value to return if no value is stored under the key |
Definition at line 81 of file Parameterised.cpp.
References Parameterised::myMap.
Referenced by MSTLLogicControl::WAUTSwitchProcedure_Stretch::adaptLogic(), MSDevice_Battery::buildVehicleDevices(), MSDevice_Example::buildVehicleDevices(), MSDevice::equippedByDefaultAssignmentOptions(), MSSOTLTrafficLightLogic::getDecayConstant(), MSTLLogicControl::WAUTSwitchProcedure::getGSPValue(), MSSOTLTrafficLightLogic::getInputSensorsLength(), MSSOTLRequestPolicy::getMinDecisionalPhaseDuration(), MSSOTLRequestTrafficLightLogic::getMinDecisionalPhaseDuration(), MSSOTLTrafficLightLogic::getMode(), MSSOTLTrafficLightLogic::getOutputSensorsLength(), MSSOTLTrafficLightLogic::getSpeedThreshold(), MSTLLogicControl::WAUTSwitchProcedure_Stretch::getStretchAreaNo(), MSTLLogicControl::WAUTSwitchProcedure_Stretch::getStretchBereichDef(), MSSOTLTrafficLightLogic::getThreshold(), PushButtonLogic::init(), MSSOTLPhasePolicy::init(), SigmoidLogic::init(), MSSOTLTrafficLightLogic::init(), MSSwarmTrafficLightLogic::init(), MSSOTLTrafficLightLogic::isDecayThresholdActivated(), MSSOTLTrafficLightLogic::isPushButtonPressed(), MSActuatedTrafficLightLogic::MSActuatedTrafficLightLogic(), MSSOTLPolicy::MSSOTLPolicy(), MSSOTLPolicy5DFamilyStimulus::MSSOTLPolicy5DFamilyStimulus(), MSSwarmTrafficLightLogic::MSSwarmTrafficLightLogic(), TraCIServerAPI_Edge::processGet(), TraCIServerAPI_POI::processGet(), TraCIServerAPI_TLS::processGet(), TraCIServerAPI_VehicleType::processGet(), TraCIServerAPI_Polygon::processGet(), TraCIServerAPI_Route::processGet(), TraCIServerAPI_Vehicle::processGet(), TraCIServerAPI_Person::processGet(), TraCIServerAPI_Lane::processGet(), MSSOTLPolicyDesirability::readParameter(), MSTLLogicControl::WAUTSwitchProcedure_Stretch::stretchLogic(), and TraCIServerAPI_Vehicle::vtdMap().
Definition at line 2476 of file MSLane.cpp.
References DEBUG_COND2, Named::getID(), MSBaseVehicle::getID(), MSVehicle::getPositionOnLane(), MSVehicle::isFrontOnLane(), myPartialVehicles, SIMTIME, and toString().
Referenced by getIncomingLanes().
|
inline |
Returns the number of vehicles partially on this lane (for which this lane is not responsible)
Definition at line 369 of file MSLane.h.
References myPartialVehicles.
|
inline |
Returns the vehicle class permissions for this lane.
Definition at line 488 of file MSLane.h.
References myPermissions.
Referenced by MSSwarmTrafficLightLogic::allowLine(), GUIApplicationWindow::onCmdEditChosen(), and TraCIServerAPI_Lane::processGet().
SUMOReal MSLane::getPMxEmissions | ( | ) | const |
Returns the sum of last step PMx emissions.
Definition at line 2124 of file MSLane.cpp.
References getVehiclesSecure(), releaseVehicles(), and SUMOReal.
Referenced by getBruttoVehLenSum(), GUILane::getColorValue(), GUILane::getScaleValue(), TraCIServerAPI_Lane::processGet(), and MSFullExport::writeLane().
|
inline |
Definition at line 901 of file MSLane.h.
References myRightmostSublane.
Referenced by MSLCM_SL2015::_wantsChangeSublane().
|
inline |
Definition at line 897 of file MSLane.h.
References myRightSideOnEdge.
Referenced by MSLCM_SL2015::_wantsChangeSublane(), MSLCM_SL2015::checkBlocking(), MSLaneChangerSublane::checkChangeSublane(), detectCollisions(), MSVehicle::getCenterOnEdge(), getFollowersOnConsecutive(), MSVehicle::getLatOffset(), MSLCM_SL2015::keepLatGap(), MSVehicle::planMoveInternal(), MSLaneChangerSublane::startChangeSublane(), and MSLaneChangerSublane::updateChanger().
|
inline |
Returns this lane's shape.
Definition at line 427 of file MSLane.h.
References myShape.
Referenced by TraCIServerAPI_Lane::StoringVisitor::add(), GUIBusStop::addAccess(), NLHandler::addConnection(), GUIE3Collector::MyWrapper::buildDefinition(), TraCIServerAPI_Simulation::commandPositionConversion(), MSVehicle::computeAngle(), GUIVehicle::drawAction_drawLinkItems(), GUILane::drawLane2LaneConnections(), fill(), TraCIServerAPI_Vehicle::findCloserLane(), MEVehicle::getAngle(), MSPModel_Striping::PState::getAngle(), MSTransportable::Stage::getLanePosition(), MSPModel_Striping::getNextLaneObstacles(), TraCIServerAPI_InductionLoop::getPosition(), GUIContainer::getPosition(), MSDevice_Battery::getPropEnergy(), TraCIServerAPI_Lane::getShape(), MEVehicle::getSlope(), MSVehicle::getSlope(), MSVTKExport::getSpeed(), TraCIServerAPI_InductionLoop::getTree(), MSStoppingPlace::getWaitPosition(), GUIBusStop::GUIBusStop(), GUIChargingStation::GUIChargingStation(), GUIContainerStop::GUIContainerStop(), MSPModel_Striping::initWalkingAreaPaths(), GUIMEInductLoop::MyWrapper::MyWrapper(), GUIInstantInductLoop::MyWrapper::MyWrapper(), GUI_E2_ZS_Collector::MyWrapper::MyWrapper(), GUIInductLoop::MyWrapper::MyWrapper(), MSDevice_Battery::notifyEnter(), MSLane::by_connections_to_sorter::operator()(), TraCIServerAPI_Lane::processGet(), TraCIServerAPI_Vehicle::processSet(), MSLink::setRequestInformation(), MSLaneChangerSublane::startChangeSublane(), TraCIServerAPI_Vehicle::vtdMap(), and MSBatteryExport::write().
|
inline |
Returns the lane's maximum allowed speed.
Definition at line 472 of file MSLane.h.
References myMaxSpeed.
Referenced by MSLCM_LC2013::_wantsChange(), MSLCM_SL2015::_wantsChangeSublane(), MSLaneChanger::changeOpposite(), MSVehicleTransfer::checkInsertions(), MSLCM_SL2015::checkStrategicChange(), MSAbstractLaneChangeModel::congested(), executeMovements(), GUILane::getColorValue(), MSE2Collector::getEstimatedCurrentVehicleNumber(), getMaximumBrakeDist(), GUILane::getParameterWindow(), GUILane::getScaleValue(), MSActuatedTrafficLightLogic::init(), TraCIServerAPI_Lane::processGet(), MSLCM_DK2008::wantsChangeToRight(), MSMeanData::writeEdge(), and MSFullExport::writeLane().
|
inline |
Returns the lane's maximum speed, given a vehicle's speed limit adaptation.
[in] | The | vehicle to return the adapted speed limit for |
Definition at line 458 of file MSLane.h.
References SUMOVehicle::getChosenSpeedFactor(), SUMOVehicle::getMaxSpeed(), SUMOVehicle::getVClass(), MIN2(), myMaxSpeed, and myRestrictions.
Referenced by MSLCM_LC2013::_wantsChange(), MSLCM_SL2015::_wantsChangeSublane(), MSLaneChanger::changeOpposite(), MSLaneChanger::computeOvertakingTime(), MEVehicle::estimateLeaveSpeed(), MSVehicle::estimateLeaveSpeed(), MSCFModel_IDM::followSpeed(), GUIVehicle::getColorValue(), getCriticalLeader(), getDepartSpeed(), getLeadersOnConsecutive(), MSVehicle::getMaxSpeedOnLane(), MSCFModel_IDM::interactionGap(), MSCFModel::interactionGap(), isInsertionSuccess(), MSCFModel_Daniel1::moveHelper(), MSCFModel_SmartSK::moveHelper(), MSCFModel_KraussOrig1::moveHelper(), MSCFModel_IDM::moveHelper(), MSVehicle::planMoveInternal(), TraCIServerAPI_Vehicle::processGet(), MSVehicle::setBlinkerInformation(), MSCFModel_IDM::stopSpeed(), MSLCM_SL2015::updateExpectedSublaneSpeeds(), MSLCM_DK2008::wantsChangeToLeft(), and MSLCM_DK2008::wantsChangeToRight().
|
inline |
Returns the number of vehicles on this lane (for which this lane is responsible)
Definition at line 353 of file MSLane.h.
References myVehicles.
Referenced by MSVehicle::checkRewindLinkLanes(), TraCIServerAPI_Lane::processGet(), MSFullExport::writeLane(), and MSXMLRawOut::writeLane().
|
inline |
Returns the number of vehicles on this lane (including partial occupators)
Definition at line 361 of file MSLane.h.
References myPartialVehicles, and myVehicles.
|
inlinevirtual |
Returns the vehicles container; locks it for microsimulation.
Please note that it is necessary to release the vehicles container afterwards using "releaseVehicles".
Reimplemented in GUILane.
Definition at line 380 of file MSLane.h.
References myVehicles.
Referenced by TraCIServerAPI_Lane::StoringVisitor::add(), getBruttoOccupancy(), getCO2Emissions(), getCOEmissions(), getElectricityConsumption(), getFuelConsumption(), getHarmonoise_NoiseEmissions(), getHCEmissions(), MSVehicle::getLeader(), getMeanSpeed(), getNettoOccupancy(), getNOxEmissions(), getPMxEmissions(), MSVehicle::getSpaceTillLastStanding(), MSPedestrianPushButton::isActiveForEdge(), and TraCIServerAPI_Lane::processGet().
SUMOReal MSLane::getWaitingSeconds | ( | ) | const |
Returns the overall waiting time on this lane.
Definition at line 2071 of file MSLane.cpp.
References myVehicles, and SUMOReal.
Referenced by getIncomingLanes(), and TraCIServerAPI_Lane::processGet().
|
inline |
Returns the lane's width.
Definition at line 496 of file MSLane.h.
References myWidth.
Referenced by MSLCM_SL2015::_wantsChangeSublane(), MSLaneChanger::continueChange(), GUILane::drawGL(), MSVehicle::executeMove(), MSVehicle::getCenterOnEdge(), MSLink::getInternalLengthsAfter(), MSVehicle::getLateralOverlap(), MSPModel_Striping::getNextLaneObstacles(), MSPModel_Striping::PState::getPosition(), MSVehicle::getRightSideOnLane(), MSPModel_Striping::initWalkingAreaPaths(), insertVehicle(), MSLCM_SL2015::keepLatGap(), MSPModel_Striping::moveInDirection(), MSPModel_Striping::PState::moveToNextLane(), MSPModel_Striping::numStripes(), MSVehicle::Influencer::postProcessVTD(), TraCIServerAPI_Lane::processGet(), TraCIServerAPI_Vehicle::processSet(), GUIVehicle::selectBlockingFoes(), MSLink::setRequestInformation(), and MSLaneChangerSublane::startChangeSublane().
|
protected |
take action upon collision
Definition at line 1132 of file MSLane.cpp.
References COLLISION_ACTION_REMOVE, COLLISION_ACTION_TELEPORT, COLLISION_ACTION_WARN, Named::getID(), MSBaseVehicle::getID(), MSVehicle::getInfluencer(), MSNet::getInstance(), MSNet::getVehicleControl(), MSVehicle::hasInfluencer(), MSVehicle::Influencer::isVTDAffected(), myCollisionAction, MSVehicleControl::registerCollision(), time2string(), toString(), and WRITE_WARNING.
Referenced by detectCollisionBetween(), and detectCollisions().
|
protectedvirtual |
Inserts the vehicle into this lane, and informs it about entering the network.
Calls the vehicles enterLaneAtInsertion function, updates statistics and modifies the active state as needed
[in] | veh | The vehicle to be incorporated |
[in] | pos | The position of the vehicle |
[in] | speed | The speed of the vehicle |
[in] | posLat | The lateral position of the vehicle |
[in] | at | |
[in] | notification | The cause of insertion (i.e. departure, teleport, parking) defaults to departure |
Reimplemented in GUILane.
Definition at line 245 of file MSLane.cpp.
References MSVehicle::enterLaneAtInsertion(), MSNet::getEdgeControl(), MSNet::getInstance(), MSVehicleType::getLength(), MSVehicleType::getLengthWithGap(), MSBaseVehicle::getVehicleType(), MSEdgeControl::gotActive(), MSEdge::markDelayed(), myBruttoVehicleLengthSum, myEdge, myLength, myNettoVehicleLengthSum, and myVehicles.
Referenced by forceVehicleInsertion(), GUILane::incorporateVehicle(), isInsertionSuccess(), and loadState().
|
static |
Definition at line 2585 of file MSLane.cpp.
References COLLISION_ACTION_NONE, COLLISION_ACTION_REMOVE, COLLISION_ACTION_TELEPORT, COLLISION_ACTION_WARN, OptionsCont::getBool(), OptionsCont::getString(), myCheckJunctionCollisions, and myCollisionAction.
Referenced by MSFrame::setMSGlobals(), and visit().
|
static |
Adds the ids of all stored lanes into the given vector.
Definition at line 1318 of file MSLane.cpp.
References myDict.
Referenced by dictSize(), and TraCIServerAPI_Lane::processGet().
bool MSLane::insertVehicle | ( | MSVehicle & | v | ) |
Tries to insert the given vehicle.
The insertion position and speed are determined in dependence to the vehicle's departure definition, first.
Then, the vehicle is tried to be inserted into the lane using these values by a call to "isInsertionSuccess". The result of "isInsertionSuccess" is returned.
[in] | v | The vehicle to insert |
Definition at line 399 of file MSLane.cpp.
References basePos(), DEPART_POS_BASE, DEPART_POS_DEFAULT, DEPART_POS_FREE, DEPART_POS_GIVEN, DEPART_POS_LAST, DEPART_POS_RANDOM, DEPART_POS_RANDOM_FREE, DEPART_POSLAT_CENTER, DEPART_POSLAT_FREE, DEPART_POSLAT_GIVEN, DEPART_POSLAT_LEFT, DEPART_POSLAT_RANDOM, DEPART_POSLAT_RANDOM_FREE, DEPART_POSLAT_RIGHT, SUMOVehicleParameter::departPos, SUMOVehicleParameter::departPosLat, SUMOVehicleParameter::departPosLatProcedure, SUMOVehicleParameter::departPosProcedure, freeInsertion(), getDepartSpeed(), getLength(), MSBaseVehicle::getParameter(), MSBaseVehicle::getVehicleType(), MSVehicleType::getWidth(), getWidth(), isInsertionSuccess(), lastInsertion(), myLength, MSMoveReminder::NOTIFICATION_DEPARTED, RandHelper::rand(), and SUMOReal.
Referenced by getMoveReminders(), and MSEdge::insertVehicle().
|
virtual |
Insert buffered vehicle into the real lane.
Reimplemented in GUILane.
Definition at line 1362 of file MSLane.cpp.
References MSVehicle::getLane(), MSVehicleType::getLength(), MSVehicleType::getLengthWithGap(), MSBaseVehicle::getVehicleType(), MSGlobals::gLateralResolution, MSEdge::markDelayed(), myBruttoVehicleLengthSum, myEdge, myNettoVehicleLengthSum, myVehBuffer, myVehicles, and sortPartialVehicles().
Referenced by getIndex(), and GUILane::integrateNewVehicle().
Definition at line 450 of file MSLane.h.
References myLengthGeometryFactor.
Referenced by GUILane::getPopUpMenu(), and MSLink::setRequestInformation().
Definition at line 438 of file MSLane.h.
References myLengthGeometryFactor.
Referenced by MSVehicle::computeAngle(), GUIEdge::drawMesoVehicles(), geometryPositionAtOffset(), MEVehicle::getAngle(), MSTransportable::Stage::getLanePosition(), MSVehicle::getPosition(), MEVehicle::getSlope(), MSVehicle::getSlope(), MSStoppingPlace::getWaitPosition(), and MSLaneChangerSublane::startChangeSublane().
bool MSLane::isApproachedFrom | ( | MSEdge *const | edge | ) |
Definition at line 1591 of file MSLane.cpp.
References myApproachingLanes.
Referenced by getIncomingLanes().
Definition at line 1597 of file MSLane.cpp.
References myApproachingLanes.
bool MSLane::isEmpty | ( | ) | const |
Returns the information whether the lane is has no vehicle and no partial occupation
Definition at line 1405 of file MSLane.cpp.
References myPartialVehicles, and myVehicles.
Referenced by dictSize().
bool MSLane::isInsertionSuccess | ( | MSVehicle * | vehicle, |
SUMOReal | speed, | ||
SUMOReal | pos, | ||
SUMOReal | posLat, | ||
bool | recheckNextLanes, | ||
MSMoveReminder::Notification | notification | ||
) |
Tries to insert the given vehicle with the given state (speed and pos)
Checks whether the vehicle can be inserted at the given position with the given speed so that no collisions with leader/follower occur and the speed does not cause unexpected behaviour on consecutive lanes. Returns false if the vehicle can not be inserted.
If the insertion can take place, incorporateVehicle() is called and true is returned.
[in] | vehicle | The vehicle to insert |
[in] | speed | The speed with which it shall be inserted |
[in] | pos | The position at which it shall be inserted |
[in] | posLat | The lateral position at which it shall be inserted |
[in] | recheckNextLanes | Forces patching the speed for not being too fast on next lanes |
[in] | notification | The cause of insertion (i.e. departure, teleport, parking) defaults to departure |
Definition at line 506 of file MSLane.cpp.
References ARRIVAL_SPEED_GIVEN, SUMOVehicleParameter::arrivalSpeed, SUMOVehicleParameter::arrivalSpeedProcedure, MSRoute::begin(), MSCFModel::brakeGap(), checkFailure(), DEBUG_COND2, MSInsertionControl::descheduleDeparture(), MSVehicle::Stop::endPos, MSCFModel::freeSpeed(), MSVehicle::getBackPositionOnLane(), MSVehicle::getBestLanesContinuation(), MSVehicle::getCarFollowModel(), MSNet::getCurrentTimeStep(), getEdge(), getFollowersOnConsecutive(), Named::getID(), MSBaseVehicle::getID(), MSBaseVehicle::getImpatience(), MSNet::getInsertionControl(), MSNet::getInstance(), getLastAnyVehicle(), MSRoute::getLastEdge(), getLastVehicleInformation(), MSVehicleType::getLength(), getLength(), MSCFModel::getMaxDecel(), MSVehicleType::getMinGap(), getMissingRearGap(), MSVehicle::getNextStop(), MSBaseVehicle::getParameter(), MSBaseVehicle::getRoute(), MSCFModel::getSecureGap(), MSVehicle::getSpeed(), getVehicleMaxSpeed(), MSBaseVehicle::getVehicleType(), MSVehicle::hasStops(), incorporateVehicle(), MSCFModel::insertionFollowSpeed(), MSCFModel::insertionStopSpeed(), isLinkEnd(), MSVehicle::Stop::lane, LINKSTATE_ALLWAY_STOP, LINKSTATE_EQUAL, LINKSTATE_MINOR, LINKSTATE_STOP, MAX2(), Named::myID, myLength, myVehicles, NUMERICAL_EPS, MSLeaderInfo::numFreeSublanes(), MSLeaderInfo::numSublanes(), safeInsertionSpeed(), MSVehicle::setTentativeLaneAndPosition(), SIMTIME, MSCFModel::stopSpeed(), succLinkSec(), SUMO_const_haltingSpeed, SUMOReal, TIME2STEPS, toString(), MSLeaderInfo::toString(), MSVehicle::updateBestLanes(), WRITE_ERROR, and WRITE_WARNING.
Referenced by MSVehicleTransfer::checkInsertions(), freeInsertion(), getMoveReminders(), insertVehicle(), and lastInsertion().
bool MSLane::isInternal | ( | ) | const |
Returns whether the lane pertains to an internal edge
Definition at line 1410 of file MSLane.cpp.
References MSEdge::EDGEFUNCTION_INTERNAL, MSEdge::getPurpose(), and myEdge.
Referenced by dictSize(), MSLCM_LC2013::distanceAlongNextRoundabout(), GUILane::drawGL(), and succLinkSec().
bool MSLane::isLinkEnd | ( | MSLinkCont::const_iterator & | i | ) | const |
Returns the information whether the given link shows at the end of the list of links (is not valid)
Definition at line 1394 of file MSLane.cpp.
References myLinks.
Referenced by MSLaneChanger::checkChange(), dictSize(), getCriticalLeader(), getLeadersOnConsecutive(), isInsertionSuccess(), MSVehicle::planMoveInternal(), TraCIServerAPI_Vehicle::processGet(), and MSVehicle::unsafeLinkAhead().
bool MSLane::isLinkEnd | ( | MSLinkCont::iterator & | i | ) |
Returns the information whether the given link shows at the end of the list of links (is not valid)
Definition at line 1400 of file MSLane.cpp.
References myLinks.
|
inherited |
Returns whether the parameter is known.
[in] | key | The key to ask for |
Definition at line 75 of file Parameterised.cpp.
References Parameterised::myMap.
Referenced by MSDevice_Example::buildVehicleDevices(), and MSDevice::equippedByDefaultAssignmentOptions().
Definition at line 265 of file MSLane.cpp.
References basePos(), MSVehicle::getCarFollowModel(), MSVehicleType::getLength(), MSCFModel::getMaxDecel(), MSVehicleType::getMinGap(), MSVehicle::getPositionOnLane(), MSCFModel::getSecureGap(), MSVehicle::getSpeed(), MSBaseVehicle::getVehicleType(), isInsertionSuccess(), myVehicles, MSMoveReminder::NOTIFICATION_DEPARTED, POSITION_EPS, and SUMOReal.
Referenced by getMoveReminders(), and insertVehicle().
void MSLane::leftByLaneChange | ( | MSVehicle * | v | ) |
Definition at line 2016 of file MSLane.cpp.
References MSVehicleType::getLength(), MSVehicleType::getLengthWithGap(), MSBaseVehicle::getVehicleType(), myBruttoVehicleLengthSum, and myNettoVehicleLengthSum.
Referenced by dictSize(), and MSAbstractLaneChangeModel::primaryLaneChanged().
void MSLane::loadState | ( | std::vector< std::string > & | vehIDs, |
MSVehicleControl & | vc | ||
) |
Loads the state of this segment with the given parameters.
This method is called for every internal que the segment has. Every vehicle is retrieved from the given MSVehicleControl and added to this lane.
[in] | vehIDs | The vehicle ids for the current que |
[in] | vc | The vehicle control to retrieve references vehicles from |
What about throwing an IOError?
What about throwing an error if something else fails (a vehicle can not be referenced)?
Definition at line 2256 of file MSLane.cpp.
References MSVehicle::getLateralPositionOnLane(), MSVehicle::getPositionOnLane(), MSVehicle::getSpeed(), MSVehicleControl::getVehicle(), incorporateVehicle(), myVehicles, MSMoveReminder::NOTIFICATION_JUNCTION, and MSVehicle::updateBestLanes().
Referenced by getCenterOnEdge().
invalidated assignment operator
Referenced by MSLane::edge_finder::operator()().
|
virtual |
Compute safe velocities for all vehicles based on positions and speeds from the last time step. Also registers ApproachingVehicleInformation for all links.
This method goes through all vehicles calling their "planMove" method.
Reimplemented in GUILane.
Definition at line 937 of file MSLane.cpp.
References MSLeaderInfo::addLeader(), DEBUG_COND, Named::getID(), myPartialVehicles, myVehicles, SIMTIME, SUMOReal, toString(), and MSLeaderInfo::toString().
Referenced by getIndex(), and GUILane::planMovements().
|
inlinevirtual |
Allows to use the container for microsimulation again.
Reimplemented in GUILane.
Definition at line 407 of file MSLane.h.
Referenced by TraCIServerAPI_Lane::StoringVisitor::add(), getBruttoOccupancy(), getCO2Emissions(), getCOEmissions(), getElectricityConsumption(), getFuelConsumption(), getHarmonoise_NoiseEmissions(), getHCEmissions(), MSVehicle::getLeader(), getMeanSpeed(), getNettoOccupancy(), getNOxEmissions(), getPMxEmissions(), MSVehicle::getSpaceTillLastStanding(), MSPedestrianPushButton::isActiveForEdge(), and TraCIServerAPI_Lane::processGet().
|
virtual |
Reimplemented in GUILane.
Definition at line 1543 of file MSLane.cpp.
References MSVehicle::getLane(), MSVehicleType::getLength(), MSVehicleType::getLengthWithGap(), MSBaseVehicle::getVehicleType(), MSVehicle::leaveLane(), myBruttoVehicleLengthSum, myNettoVehicleLengthSum, and myVehicles.
Referenced by detectCollisions(), dictSize(), MSVehicle::Influencer::postProcessVTD(), TraCIServerAPI_Vehicle::processSet(), MSCalibrator::removePending(), and GUILane::removeVehicle().
|
virtual |
Removes the information about a vehicle lapping into this lane.
[in] | v | The vehicle which laps into this lane |
Reimplemented in GUILane.
Definition at line 225 of file MSLane.cpp.
References DEBUG_COND2, Named::getID(), MSBaseVehicle::getID(), myPartialVehicles, and SIMTIME.
Referenced by MSAbstractLaneChangeModel::cleanupShadowLane(), getMoveReminders(), GUILane::resetPartialOccupation(), and MSAbstractLaneChangeModel::updateShadowLane().
void MSLane::resetPermissions | ( | long | transientID | ) |
Definition at line 2615 of file MSLane.cpp.
References myOriginalPermissions, myPermissionChanges, myPermissions, and SVCAll.
Referenced by GUILane::closeTraffic(), dictSize(), and setPermissions().
|
protected |
return the maximum safe speed for insertion behind leaders (a negative value indicates that safe insertion is impossible)
Definition at line 815 of file MSLane.cpp.
References MSVehicle::getBackPositionOnLane(), MSVehicle::getCarFollowModel(), MSCFModel::getMaxDecel(), MSVehicleType::getMinGap(), MSVehicle::getPositionOnLane(), MSVehicle::getSpeed(), MSBaseVehicle::getVehicleType(), MSCFModel::insertionFollowSpeed(), MIN2(), MSLeaderInfo::numSublanes(), and SUMOReal.
Referenced by isInsertionSuccess().
void MSLane::saveState | ( | OutputDevice & | out | ) |
Saves the state of this lane into the given stream.
Basically, a list of vehicle ids
Definition at line 2245 of file MSLane.cpp.
References OutputDevice::closeTag(), Named::getID(), myVehicles, OutputDevice::openTag(), SUMO_ATTR_VALUE, SUMO_TAG_LANE, SUMO_TAG_VIEWSETTINGS_VEHICLES, and OutputDevice::writeAttr().
Referenced by getCenterOnEdge().
|
inlineinherited |
resets the id
[in] | newID | The 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().
void MSLane::setLength | ( | SUMOReal | val | ) |
Sets a new length for the lane (used by TraCI only)
[in] | val | the new length in m |
Definition at line 1525 of file MSLane.cpp.
References myEdge, and MSEdge::recalcCache().
Referenced by empty(), and TraCIServerAPI_Lane::processSet().
void MSLane::setMaxSpeed | ( | SUMOReal | val | ) |
Sets a new maximum speed for the lane (used by TraCI and MSCalibrator)
[in] | val | the new speed in m/s |
Definition at line 1518 of file MSLane.cpp.
References myEdge, myMaxSpeed, and MSEdge::recalcCache().
Referenced by empty(), and TraCIServerAPI_Lane::processSet().
Sets the information about a vehicle lapping into this lane.
This vehicle is added to myVehicles and may be distinguished from regular vehicles by the disparity between this lane and v->getLane()
[in] | v | The vehicle which laps into this lane |
Reimplemented in GUILane.
Definition at line 212 of file MSLane.cpp.
References DEBUG_COND2, Named::getID(), MSBaseVehicle::getID(), myLength, myPartialVehicles, and SIMTIME.
Referenced by getMoveReminders(), GUILane::setPartialOccupation(), and MSAbstractLaneChangeModel::updateShadowLane().
void MSLane::setPermissions | ( | SVCPermissions | permissions, |
long | transientID | ||
) |
Sets the permissions to the given value. If a transientID is given, the permissions are recored as temporary.
[in] | permissions | The new permissions |
[in] | transientID | The id of the permission-modification or the special value PERMANENT |
Definition at line 2603 of file MSLane.cpp.
References CHANGE_PERMISSIONS_PERMANENT, myOriginalPermissions, myPermissionChanges, myPermissions, and resetPermissions().
Referenced by GUILane::closeTraffic(), dictSize(), and TraCIServerAPI_Lane::processSet().
|
inline |
Definition at line 892 of file MSLane.h.
References myRightmostSublane, and myRightSideOnEdge.
void MSLane::sortPartialVehicles | ( | ) |
sorts myPartialVehicles
Definition at line 1387 of file MSLane.cpp.
References myPartialVehicles.
Referenced by getCenterOnEdge(), integrateNewVehicle(), and swapAfterLaneChange().
|
static |
Same as succLink, but does not throw any assertions when the succeeding link could not be found; Returns the myLinks.end() instead; Further, the number of edges to look forward may be given
Definition at line 1461 of file MSLane.cpp.
References Named::getID(), SUMOVehicle::getID(), MSNet::getInstance(), MSVehicleType::getVehicleClass(), SUMOVehicle::getVehicleType(), isInternal(), myLinks, SUMOVehicle::succEdge(), time2string(), and WRITE_WARNING.
Referenced by appropriate(), MSLaneChanger::checkChange(), dictSize(), executeMovements(), getCriticalLeader(), getLeaderOnConsecutive(), getLeadersOnConsecutive(), isInsertionSuccess(), MSVehicle::planMoveInternal(), TraCIServerAPI_Vehicle::processGet(), MSVehicle::setBlinkerInformation(), and MSVehicle::unsafeLinkAhead().
|
protectedvirtual |
moves myTmpVehicles int myVehicles after a lane change procedure
Reimplemented in GUILane.
Definition at line 1532 of file MSLane.cpp.
References myTmpVehicles, myVehicles, and sortPartialVehicles().
Referenced by GUILane::swapAfterLaneChange().
|
inlinestatic |
Definition at line 973 of file MSLane.h.
References COLLISION_ACTION_TELEPORT, and myCollisionAction.
Referenced by MSVehicleControl::getTeleportCount().
|
inline |
Callback for visiting the lane when traversing an RTree.
This is used in the TraCIServerAPI_Lane for context subscriptions.
[in] | cont | The context doing all the work |
Definition at line 966 of file MSLane.h.
References TraCIServerAPI_Lane::StoringVisitor::add(), and initCollisionOptions().
Referenced by TraCIServer::collectObjectsInRange().
|
friend |
Definition at line 88 of file MSLane.h.
Referenced by anyVehiclesBegin(), anyVehiclesEnd(), anyVehiclesUpstreamBegin(), and anyVehiclesUpstreamEnd().
|
friend |
|
friend |
|
friend |
|
friend |
|
static |
Definition at line 978 of file MSLane.h.
Referenced by GUILane::closeTraffic().
|
static |
Definition at line 977 of file MSLane.h.
Referenced by TraCIServerAPI_Edge::processSet(), TraCIServerAPI_Lane::processSet(), and setPermissions().
Definition at line 1106 of file MSLane.h.
Referenced by addApproachingLane(), and isApproachedFrom().
|
protected |
The current length of all vehicles on this lane, including their minGaps.
Definition at line 1097 of file MSLane.h.
Referenced by enteredByLaneChange(), executeMovements(), getBruttoOccupancy(), getBruttoVehLenSum(), incorporateVehicle(), integrateNewVehicle(), leftByLaneChange(), and removeVehicle().
|
staticprivate |
Definition at line 1146 of file MSLane.h.
Referenced by detectCollisions(), and initCollisionOptions().
|
staticprivate |
the action to take on collisions
Definition at line 1145 of file MSLane.h.
Referenced by detectCollisionBetween(), detectCollisions(), handleCollisionBetween(), initCollisionOptions(), and teleportOnCollision().
|
staticprotected |
Static dictionary to associate string-ids with objects.
Definition at line 1138 of file MSLane.h.
Referenced by clear(), dictionary(), dictSize(), fill(), and insertIDs().
|
protected |
The lane's edge, for routing only.
Definition at line 1078 of file MSLane.h.
Referenced by appropriate(), detectCollisions(), GUILane::drawGL(), GUILane::drawMarkings(), GUILane::getColorValue(), getEdge(), GUILane::getEdgeLaneNumber(), getInternalFollower(), GUILane::getLoadedEdgeWeight(), getLogicalPredecessorLane(), getParallelLane(), GUILane::getParameterWindow(), GUILane::getScaleValue(), GUILane::getStoredEdgeTravelTime(), incorporateVehicle(), integrateNewVehicle(), isInternal(), setLength(), and setMaxSpeed().
|
mutableprotected |
followers on all sublanes as seen by vehicles on consecutive lanes (cached)
Definition at line 1111 of file MSLane.h.
Referenced by getFirstVehicleInformation().
|
mutableprotected |
time step for which myFollowerInfo was last updated
Definition at line 1118 of file MSLane.h.
Referenced by getFirstVehicleInformation().
|
protectedinherited |
The name of the object.
Definition at line 136 of file Named.h.
Referenced by GUI_E2_ZS_CollectorOverLanes::buildCollector(), RODFDetector::buildDestinationDistribution(), NGEdge::buildNBEdge(), NGNode::buildNBNode(), MSSOTLTrafficLightLogic::checkPhases(), NBNode::computeNodeShape(), METriggeredCalibrator::execute(), MSCalibrator::execute(), Named::getID(), NBEdge::getLaneID(), NBEdge::getLaneIDInsecure(), ROEdge::getStoredEffort(), ROEdge::getTravelTime(), MSActuatedTrafficLightLogic::init(), MSSOTLTrafficLightLogic::init(), MSCalibrator::init(), NBEdge::init(), isInsertionSuccess(), MSCalibrator::myStartElement(), MSMeanData::openInterval(), RORouteDef::preComputeCurrentRoute(), NBEdge::reinitNodes(), MSRoute::release(), Named::setID(), MSSOTLTrafficLightLogic::setToATargetPhase(), NBEdge::splitGeometry(), RODFDetector::writeEmitterDefinition(), MSXMLRawOut::writeLane(), NBNode::writeLogic(), RODFDetector::writeSingleSpeedTrigger(), MEInductLoop::writeXMLOutput(), MSCalibrator::writeXMLOutput(), and MSE3Collector::writeXMLOutput().
|
protected |
Definition at line 1092 of file MSLane.h.
Referenced by addIncomingLane(), getFollowerOnConsecutive(), getFollowersOnConsecutive(), getIncomingLanes(), and getLogicalPredecessorLane().
|
protected |
The lane index.
Definition at line 1035 of file MSLane.h.
Referenced by GUILane::drawMarkings(), and getIndex().
|
mutableprotected |
leaders on all sublanes as seen by approaching vehicles (cached)
Definition at line 1109 of file MSLane.h.
Referenced by getLastVehicleInformation().
|
mutableprotected |
time step for which myLeaderInfo was last updated
Definition at line 1116 of file MSLane.h.
Referenced by getLastVehicleInformation().
|
mutableprotected |
Definition at line 1113 of file MSLane.h.
Referenced by getFirstVehicleInformation(), and getLastVehicleInformation().
|
protected |
Lane length [m].
Definition at line 1072 of file MSLane.h.
Referenced by basePos(), freeInsertion(), getBruttoOccupancy(), GUILane::getColorValue(), getLength(), getNettoOccupancy(), GUILane::getParameterWindow(), GUILane::getScaleValue(), incorporateVehicle(), insertVehicle(), isInsertionSuccess(), setPartialOccupation(), and GUILane::splitAtSegments().
|
protected |
precomputed myShape.length / myLength
Definition at line 1121 of file MSLane.h.
Referenced by GUILane::getColorValue(), getLengthGeometryFactor(), GUILane::getScaleValue(), interpolateGeometryPosToLanePos(), and interpolateLanePosToGeometryPos().
|
protected |
The lane's Links to it's succeeding lanes and the default right-of-way rule, i.e. blocked or not blocked.
Definition at line 1104 of file MSLane.h.
Referenced by addLink(), appropriate(), detectCollisions(), GUILane::drawArrows(), GUILane::drawLane2LaneConnections(), GUILane::drawLinkNo(), GUILane::drawLinkRules(), GUILane::drawTLSLinkNo(), executeMovements(), getCrossingIndex(), getLinkCont(), getOutgoingLanes(), isLinkEnd(), succLinkSec(), and ~MSLane().
|
mutableprotected |
Definition at line 1093 of file MSLane.h.
Referenced by getLogicalPredecessorLane().
|
protected |
Lane-wide speedlimit [m/s].
Definition at line 1081 of file MSLane.h.
Referenced by GUILane::getColorValue(), getMeanSpeed(), GUILane::getScaleValue(), getSpeedLimit(), getVehicleMaxSpeed(), and setMaxSpeed().
|
private |
This lane's move reminder.
Definition at line 1142 of file MSLane.h.
Referenced by addMoveReminder(), and getMoveReminders().
|
protected |
Definition at line 1129 of file MSLane.h.
Referenced by addNeigh(), and getOpposite().
|
protected |
The current length of all vehicles on this lane, excluding their minGaps.
Definition at line 1100 of file MSLane.h.
Referenced by enteredByLaneChange(), executeMovements(), getNettoOccupancy(), incorporateVehicle(), integrateNewVehicle(), leftByLaneChange(), and removeVehicle().
|
protected |
Unique numerical ID (set on reading by netload)
Definition at line 1029 of file MSLane.h.
Referenced by getNumericalID().
|
protected |
The original vClass permissions for this lane (before temporary modifications)
Definition at line 1087 of file MSLane.h.
Referenced by resetPermissions(), and setPermissions().
|
protected |
The lane's partial vehicles. This container holds all vehicles that are partially on this lane but which are in myVehicles of another lane. Reasons for partial occupancie include the following.
The entering vehicles are inserted at the front of this container and the leaving ones leave from the back.
Definition at line 1060 of file MSLane.h.
Referenced by anyVehiclesBegin(), anyVehiclesEnd(), anyVehiclesUpstreamBegin(), detectCollisions(), freeInsertion(), getBruttoOccupancy(), getFirstAnyVehicle(), getLastAnyVehicle(), getLeaderOnConsecutive(), getLeadersOnConsecutive(), getNettoOccupancy(), getPartialBehind(), getPartialVehicleNumber(), MSLaneChanger::getRealLeader(), getVehicleNumberWithPartials(), isEmpty(), MSLane::AnyVehicleIterator::nextIsMyVehicles(), MSLane::AnyVehicleIterator::operator*(), planMovements(), resetPartialOccupation(), setPartialOccupation(), and sortPartialVehicles().
|
protected |
Definition at line 1132 of file MSLane.h.
Referenced by GUILane::closeTraffic(), GUILane::getPopUpMenu(), resetPermissions(), and setPermissions().
|
protected |
The vClass permissions for this lane.
Definition at line 1084 of file MSLane.h.
Referenced by allowsVehicleClass(), GUILane::drawAsRailway(), GUILane::drawAsWaterway(), GUILane::drawGL(), GUILane::drawMarkings(), GUILane::getColorValue(), GUILane::getParameterWindow(), getPermissions(), resetPermissions(), and setPermissions().
|
protected |
The vClass speed restrictions for this lane.
Definition at line 1090 of file MSLane.h.
Referenced by getVehicleMaxSpeed(), and MSLane().
|
protected |
the index of the rightmost sublane of this lane on myEdge
Definition at line 1126 of file MSLane.h.
Referenced by getRightmostSublane(), and setRightSideOnEdge().
|
protected |
the combined width of all lanes with lower index on myEdge
Definition at line 1124 of file MSLane.h.
Referenced by getCenterOnEdge(), getRightSideOnEdge(), and setRightSideOnEdge().
|
protected |
The shape of the lane.
Definition at line 1032 of file MSLane.h.
Referenced by GUILane::drawGL(), geometryPositionAtOffset(), GUILane::getCenteringBoundary(), GUILane::getPopUpMenu(), GUILane::getShape(), getShape(), GUILane::GUILane(), GUILane::setFunctionalColor(), and GUILane::setMultiColor().
|
protected |
Container for lane-changing vehicles. After completion of lane-change- process, the containers will be swapped with myVehicles.
Definition at line 1064 of file MSLane.h.
Referenced by getLeader(), and swapAfterLaneChange().
|
protected |
Buffer for vehicles that moved from their previous lane onto this one. Integrated after all vehicles executed their moves.
Definition at line 1068 of file MSLane.h.
Referenced by empty(), executeMovements(), integrateNewVehicle(), and MSXMLRawOut::writeLane().
|
protected |
The lane's vehicles. This container holds all vehicles that have their front (longitudinally) and their center (laterally) on this lane. These are the vehicles that this lane is 'responsibly' for (i.e. when executing movements)
The entering vehicles are inserted at the front of this container and the leaving ones leave from the back, e.g. the vehicle in front of the junction (often called first) is myVehicles.back() (if it exists). And if it is an iterator at a vehicle, ++it points to the vehicle in front. This is the interaction vehicle.
Definition at line 1048 of file MSLane.h.
Referenced by addMoveReminder(), anyVehiclesBegin(), anyVehiclesEnd(), anyVehiclesUpstreamBegin(), detectCollisions(), empty(), executeMovements(), GUILane::firstWaitingTime(), forceVehicleInsertion(), freeInsertion(), getBruttoOccupancy(), getFirstAnyVehicle(), getFirstFullVehicle(), getLastAnyVehicle(), getLastFullVehicle(), getLeader(), getMeanSpeed(), getNettoOccupancy(), getVehicleNumber(), getVehicleNumberWithPartials(), GUILane::getVehiclesSecure(), getVehiclesSecure(), getWaitingSeconds(), incorporateVehicle(), integrateNewVehicle(), isEmpty(), isInsertionSuccess(), lastInsertion(), loadState(), MSLane::AnyVehicleIterator::nextIsMyVehicles(), MSLane::AnyVehicleIterator::operator*(), planMovements(), removeVehicle(), saveState(), swapAfterLaneChange(), MSQueueExport::writeLane(), and MSXMLRawOut::writeLane().
|
protected |
Lane width [m].
Definition at line 1075 of file MSLane.h.
Referenced by GUILane::drawArrows(), GUILane::drawDirectionIndicators(), GUILane::drawLinkNo(), GUILane::drawLinkRules(), GUILane::drawTLSLinkNo(), getCenterOnEdge(), GUILane::getParameterWindow(), getWidth(), and GUILane::GUILane().