22 #ifndef SUMORouteHandler_h
23 #define SUMORouteHandler_h
71 const SUMOReal minLength,
const bool friendlyPos);
112 virtual void closeRoute(
const bool mayBeDisconnected =
false) = 0;
virtual void openVehicleTypeDistribution(const SUMOSAXAttributes &attrs)=0
virtual void myEndElement(int element)
Called when a closing tag occurs.
SUMOVehicleParameter * myVehicleParameter
Parameter of the current vehicle, trip, person, or flow.
SUMOTime myEndDefault
The default value for flow ends.
Structure representing possible vehicle parameter.
virtual void addStop(const SUMOSAXAttributes &attrs)=0
Processing of a stop.
static bool checkStopPos(SUMOReal &startPos, SUMOReal &endPos, const SUMOReal laneLength, const SUMOReal minLength, const bool friendlyPos)
check start and end position of a stop
SUMOVTypeParameter * myCurrentVType
The currently parsed vehicle type.
SUMOReal myActiveRouteProbability
The id of the current route.
SUMORouteHandler & operator=(const SUMORouteHandler &s)
Invalidated assignment operator.
virtual void openRouteDistribution(const SUMOSAXAttributes &attrs)=0
void registerLastDepart()
save last depart (only to be used if vehicle is not discarded)
std::string myActiveRouteID
The id of the current route.
SAX-handler base for SUMO-files.
IDSupplier myIdSupplier
generates numerical ids
SUMOTime myBeginDefault
The default value for flow begins.
virtual void closeVehicle()=0
Ends the processing of a vehicle.
Encapsulated SAX-Attributes.
void addParam(const SUMOSAXAttributes &attrs)
assign arbitrary vehicle parameters
virtual ~SUMORouteHandler()
standard destructor
SUMORouteHandler(const std::string &file)
standard constructor
virtual void closeRoute(const bool mayBeDisconnected=false)=0
Parser for routes during their loading.
std::vector< SUMOVehicleParameter::Stop > myActiveRouteStops
List of the stops on the parsed route.
Structure representing possible vehicle parameter.
virtual void myStartElement(int element, const SUMOSAXAttributes &attrs)
Called on the opening of a tag;.
virtual void closeVehicleTypeDistribution()=0
SUMOTime myLastDepart
The insertion time of the vehicle read last.
Definition of vehicle stop (position and duration)
bool parseStop(SUMOVehicleParameter::Stop &stop, const SUMOSAXAttributes &attrs, std::string errorSuffix, MsgHandler *const errorOutput)
parses attributes common to all stops
virtual void closeRouteDistribution()=0
virtual void closeFlow()=0
Ends the processing of a flow.
const RGBColor * myActiveRouteColor
The currently parsed route's color.
virtual void closePerson()=0
Ends the processing of a person.
SUMOTime getLastDepart() const
Returns the last loaded depart time.
bool checkLastDepart()
Checks whether the route file is sorted by departure time if needed.
std::string myActiveRouteRefID
The id of the route the current route references to.
virtual void openRoute(const SUMOSAXAttributes &attrs)=0