82 static int numSegmentsFor(
const double length,
const double slength);
The main mesocopic simulation loop.
MESegment * nextSegment(MESegment *s, MEVehicle *v)
Retrieve next segment.
static bool isEnteringRoundabout(const MSEdge &e)
whether the given edge is entering a roundabout
MELoop(const MELoop &)
Invalidated copy constructor.
void updateSegmentsForEdge(const MSEdge &e)
Update segments after loading meso edge type parameters from additional file.
SUMOTime changeSegment(MEVehicle *veh, SUMOTime leaveTime, MESegment *const toSegment, MSMoveReminder::Notification reason, const bool ignoreLink=false) const
change to the next segment this handles combinations of the following cases: (ending / continuing rou...
MESegment * getSegmentForEdge(const MSEdge &e, double pos=0)
Get the segment for a given edge at a given position.
MELoop & operator=(const MELoop &)
Invalidated assignment operator.
const SUMOTime myLinkRecheckInterval
the interval at which to recheck at blocked junctions (<=0 means asap)
void simulate(SUMOTime tMax)
Perform simulation up to the given time.
bool removeLeaderCar(MEVehicle *v)
Removes the given car from the leading vehicles.
const SUMOTime myFullRecheckInterval
the interval at which to recheck at full segments (<=0 means asap)
void vaporizeCar(MEVehicle *v, MSMoveReminder::Notification reason)
remove the given car and clean up the relevant data structures
void addLeaderCar(MEVehicle *veh, MSLink *link)
Adds the given car to the leading vehicles.
void clearState()
Remove all vehicles before quick-loading state.
std::vector< MESegment * > myEdges2FirstSegments
mapping from internal edge ids to their initial segments
std::map< SUMOTime, std::vector< MEVehicle * > > myLeaderCars
leader cars in the segments sorted by exit time
void checkCar(MEVehicle *veh)
Check whether the vehicle may move.
void teleportVehicle(MEVehicle *veh, MESegment *const toSegment, bool disconnected)
teleports a vehicle or continues a teleport
static int numSegmentsFor(const double length, const double slength)
Compute number of segments per edge (best value stay close to the configured segment length)
void buildSegmentsFor(const MSEdge &e, const OptionsCont &oc)
Build the segments for a given edge.
A single mesoscopic segment (cell)
A vehicle from the mesoscopic point of view.
A road/street connecting two junctions.
Notification
Definition of a vehicle state.
The class responsible for building and deletion of vehicles.
A storage for options typed value containers)