80 virtual void addEdgeWeight(
const std::string&
id,
double val,
double beg,
double end)
const {
88 double val,
double beg,
double end)
const {
97 virtual void addTazRelWeight(
const std::string intervalID,
const std::string& from,
const std::string& to,
98 double val,
double beg,
double end) {
158 SAXWeightsHandler(
const std::vector<ToRetrieveDefinition*>& defs,
const std::string& file);
#define UNUSED_PARAMETER(x)
Interface for a class which obtains read weights for named edges.
EdgeFloatTimeLineRetriever & operator=(const EdgeFloatTimeLineRetriever &)=delete
we made the assignment operator invalid
virtual ~EdgeFloatTimeLineRetriever()
Destructor.
virtual void addTazRelWeight(const std::string intervalID, const std::string &from, const std::string &to, double val, double beg, double end)
virtual void addEdgeWeight(const std::string &id, double val, double beg, double end) const
Adds a weight for a given edge and time period.
EdgeFloatTimeLineRetriever()
Constructor.
virtual void addEdgeRelWeight(const std::string &from, const std::string &to, double val, double beg, double end) const
Complete definition about what shall be retrieved and where to store it.
std::string myAttributeName
The attribute name that shall be parsed.
EdgeFloatTimeLineRetriever & myDestination
The class that shall be called when new data is avaiable.
int myNoLanes
The number of lanes read for the current edge.
~ToRetrieveDefinition()
Destructor.
double myAggValue
Aggregated value over the lanes read within the current edge.
bool myAmEdgeBased
Information whether edge values shall be used (lane value if false)
ToRetrieveDefinition(const ToRetrieveDefinition &)=delete
Invalidated copy constructor.
bool myHadAttribute
Information whether the attribute has been found for the current edge.
ToRetrieveDefinition & operator=(const ToRetrieveDefinition &)=delete
Invalidated assignment operator.
An XML-handler for network weights.
SAXWeightsHandler(const SAXWeightsHandler &src)=delete
we made the copy constructor invalid
double myCurrentTimeEnd
the end of the time period that is currently processed
double myCurrentTimeBeg
the begin of the time period that is currently processed
void myEndElement(int elemente)
Called when a closing tag occurs.
SAXWeightsHandler & operator=(const SAXWeightsHandler &src)=delete
we made the assignment operator invalid
void tryParseTazRel(const SUMOSAXAttributes &attrs)
Parses the data of an tazRelation for the previously read times.
~SAXWeightsHandler()
Destructor.
void tryParseEdgeRel(const SUMOSAXAttributes &attrs)
Parses the data of an edgeRelation for the previously read times.
void myStartElement(int element, const SUMOSAXAttributes &attrs)
Called on the opening of a tag;.
void tryParse(const SUMOSAXAttributes &attrs, bool isEdge)
Parses the data of an edge or lane for the previously read times.
std::string myCurrentEdgeID
the edge which is currently being processed
std::string myCurrentID
the id of the interval being parsed
std::vector< ToRetrieveDefinition * > myDefinitions
List of definitions what shall be read and whereto stored while parsing the file.
Encapsulated SAX-Attributes.
SAX-handler base for SUMO-files.