 |
Eclipse SUMO - Simulation of Urban MObility
|
Go to the documentation of this file.
69 while (st.hasNext()) {
70 std::string
id = st.next();
72 if (edge ==
nullptr) {
73 throw ProcessError(
"The edge '" +
id +
"' declared as a sink is not known.");
83 while (st.hasNext()) {
84 std::string
id = st.next();
86 if (edge ==
nullptr) {
87 throw ProcessError(
"The edge '" +
id +
"' declared as a source is not known.");
111 WRITE_ERROR(
"The edge '" +
id +
"' is not known within the network (within a 'from-edge' tag).");
130 if (edge ==
nullptr) {
131 WRITE_ERROR(
"The edge '" +
id +
"' is not known within the network (within a 'to-edge' tag).");
136 if (probability < 0) {
137 WRITE_ERROR(
"'probability' must be positive (in definition of to-edge '" +
id +
"').");
virtual bool hasAttribute(int id) const =0
Returns the information whether the named (by its enum-value) attribute is within the current list.
@ SUMO_TAG_SOURCE
a source
SAX-handler base for SUMO-files.
ROJTRTurnDefLoader(RONet &net)
Constructor.
ROEdge * getEdge(const std::string &name) const
Retrieves an edge from the network.
T get(int attr, const char *objectid, bool &ok, bool report=true) const
Tries to read given attribute assuming it is an int.
The router's network representation.
static const int WHITECHARS
identifier for splitting the given string at all whitespace characters
void myStartElement(int element, const SUMOSAXAttributes &attrs)
Called on the opening of a tag;.
void setSource(const bool isSource=true)
Sets whether the edge is a source.
double myIntervalBegin
The begin and the end of the current interval.
ROJTREdge * myEdge
The current incoming edge the turning probabilities are set into.
@ SUMO_ATTR_BEGIN
weights: time range begin
An edge the jtr-router may route through.
void addToEdge(const SUMOSAXAttributes &attrs)
Parses the probability to use a certain outgoing edge.
@ SUMO_ATTR_EDGES
the edges of a route
void setSink(const bool isSink=true)
Sets whether the edge is a sink.
@ SUMO_TAG_SINK
Sink(s) specification.
@ SUMO_TAG_TOEDGE
Outgoing edge specification (jtrrouter)
void addFollowerProbability(ROJTREdge *follower, double begTime, double endTime, double probability)
adds the information about the percentage of using a certain follower
A basic edge for routing applications.
@ SUMO_ATTR_END
weights: time range end
@ SUMO_TAG_FROMEDGE
Incoming edge specification (jtrrouter)
@ SUMO_TAG_INTERVAL
an aggreagated-output interval
RONet & myNet
The network to set the information into.
Encapsulated SAX-Attributes.
void beginFromEdge(const SUMOSAXAttributes &attrs)
Begins the processing of a incoming edge definition.
~ROJTRTurnDefLoader()
Destructor.