103 quota = (int)(flowSize *
myScale + 0.5);
111 for (
int i = 0; i < quota; i++) {
118 depart += departOffset;
#define WRITE_WARNINGF(...)
const long long int VEHPARS_TO_TAZ_SET
const long long int VEHPARS_FROM_TAZ_SET
@ SUMO_TAG_VEHICLE
description of a vehicle
@ SUMO_TAG_FLOW
a flow definition using from and to edges or a route
@ SUMO_TAG_PARAM
parameter associated to a certain key
@ SUMO_TAG_TRIP
a single trip definition (used by router)
@ SUMO_ATTR_FROM_JUNCTION
int getScalingQuota(double frac, int loaded)
Returns the number of instances of the current object that shall be emitted given the number of loade...
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
An O/D (origin/destination) matrix.
A storage for options typed value containers).
const StringVector & getStringVector(const std::string &name) const
Returns the list of string-value of the named option (only for Option_StringVector).
static OptionsCont & getOptions()
Retrieves the options.
void myEndElement(int element)
Callback method for a closing tag to implement by derived classes.
void myStartElement(int element, const SUMOSAXAttributes &attrs)
Called on the opening of a tag;.
std::vector< std::string > myTazParamKeys
The keys for reading taz.
double myScale
scale for loading vehicles
ODMatrix & myMatrix
The matrix to fill.
SUMOVehicleParameter * myVehicleParameter
The current vehicle parameters.
ROMARouteHandler(ODMatrix &matrix)
standard constructor
virtual ~ROMARouteHandler()
standard destructor
const bool myIgnoreTaz
whether to ignore attributes fromTaz, toTaz
int myNumLoaded
number of parsed vehicles
Encapsulated SAX-Attributes.
virtual std::string getString(int id, bool *isPresent=nullptr) const =0
Returns the string-value of the named (by its enum-value) attribute.
virtual bool hasAttribute(int id) const =0
Returns the information whether the named (by its enum-value) attribute is within the current list.
SUMOSAXHandler(const std::string &file="", const std::string &expectedRoot="")
Constructor.
Structure representing possible vehicle parameter.
std::string id
The vehicle's id.
static SUMOVehicleParameter * parseVehicleAttributes(int element, const SUMOSAXAttributes &attrs, const bool hardFail, const bool optionalID=false, const bool skipDepart=false, const bool allowInternalRoutes=false)
Parses a vehicle's attributes.
static SUMOVehicleParameter * parseFlowAttributes(SumoXMLTag tag, const SUMOSAXAttributes &attrs, const bool hardFail, const bool needID, const SUMOTime beginDefault, const SUMOTime endDefault, const bool allowInternalRoutes=false)
Parses a flow's attributes.