78 const bool isPermanent,
const RGBColor*
const c,
79 const std::vector<SUMOVehicleParameter::Stop>& stops);
179 const std::vector<SUMOVehicleParameter::Stop>&
getStops()
const;
228 static void checkDist(
const std::string&
id);
230 static void insertIDs(std::vector<std::string>& into);
249 std::vector<SUMOVehicleParameter::Stop>
myStops;
253 typedef std::map<std::string, const MSRoute*>
RouteDict;
259 typedef std::map<std::string, std::pair<RandomDistributor<const MSRoute*>*,
bool> >
RouteDistDict;
265 static FXMutex myDictMutex;
std::vector< const MSEdge * > ConstMSEdgeVector
std::map< std::string, const MSRoute * > RouteDict
Definition of the dictionary container.
int writeEdgeIDs(OutputDevice &os, const MSEdge *const from, const MSEdge *const upTo=0) const
Output the edge ids up to but not including the id of the given edge.
MSRoute & operator=(const MSRoute &s)
const MSEdge * getLastEdge() const
returns the destination edge
void setCosts(SUMOReal costs)
Sets the costs of the route.
std::vector< const MSEdge * > ConstMSEdgeVector
static RandomDistributor< const MSRoute * > * distDictionary(const std::string &id)
Returns the named route distribution.
const std::vector< SUMOVehicleParameter::Stop > & getStops() const
Returns the stops.
static void dict_saveState(OutputDevice &out)
Saves all known routes into the given stream.
static void insertIDs(std::vector< std::string > &into)
A road/street connecting two junctions.
SUMOReal myCosts
The assigned or calculated costs.
static void clear()
Clears the dictionary (delete all known routes, too)
SUMOReal getDistanceBetween(SUMOReal fromPos, SUMOReal toPos, const MSEdge *fromEdge, const MSEdge *toEdge, bool includeInternal=true) const
Compute the distance between 2 given edges on this route, including the length of internal lanes...
static RouteDistDict myDistDict
The dictionary container.
int size() const
Returns the number of edges to pass.
MSRoute(const std::string &id, const ConstMSEdgeVector &edges, const bool isPermanent, const RGBColor *const c, const std::vector< SUMOVehicleParameter::Stop > &stops)
Constructor.
ConstMSEdgeVector::const_iterator MSRouteIterator
bool contains(const MSEdge *const edge) const
const ConstMSEdgeVector & getEdges() const
std::map< std::string, std::pair< RandomDistributor< const MSRoute * > *, bool > > RouteDistDict
Definition of the dictionary container.
virtual ~MSRoute()
Destructor.
std::vector< MSEdge * > MSEdgeVector
SUMOReal getCosts() const
Returns the costs of the route.
An upper class for objects with additional parameters.
void addReference() const
increments the reference counter for the route
std::vector< SUMOVehicleParameter::Stop > myStops
List of the stops on the parsed route.
Base class for objects which have an id.
const bool myAmPermanent
whether the route may be deleted after the last vehicle abandoned it
MSRouteIterator end() const
Returns the end of the list of edges to pass.
ConstMSEdgeVector myEdges
The list of edges to pass.
int myReferenceCounter
Information by how many vehicles the route is used.
Static storage of an output device and its base (abstract) implementation.
const RGBColor & getColor() const
Returns the color.
const MSEdge * operator[](int index) const
std::vector< MSEdge * > MSEdgeVector
void release() const
deletes the route if there are no further references to it
static void checkDist(const std::string &id)
Checks the distribution whether it is permanent and deletes it if not.
static RouteDict myDict
The dictionary container.
const RGBColor *const myColor
The color.
MSRouteIterator begin() const
Returns the begin of the list of edges to pass.
static bool dictionary(const std::string &id, const MSRoute *route)
Adds a route to the dictionary.
bool containsAnyOf(const MSEdgeVector &edgelist) const