64 static void addTrip(std::vector<PlanItem*>& plan,
const std::string&
id,
66 const double departPos,
const std::string& stopOrigin,
67 const double arrivalPos,
const std::string& busStop,
68 double walkFactor,
const std::string& group);
70 static void addRide(std::vector<PlanItem*>& plan,
const ROEdge*
const from,
const ROEdge*
const to,
const std::string& lines,
71 double arrivalPos,
const std::string& destStop,
const std::string& group);
73 static void addWalk(std::vector<PlanItem*>& plan,
const ConstROEdgeVector& edges,
const double duration,
const double speed,
74 const double departPos,
const double arrivalPos,
const std::string& busStop);
205 const std::string& _lines,
const std::string& _group,
const double cost,
206 const double arrivalPos,
const double _length,
207 const std::string& _destStop =
"",
const std::string& _intended =
"",
const SUMOTime _depart = -1) :
220 return new Ride(
myStart,
from,
to,
lines,
group,
myCost,
arrPos,
length,
destStop,
intended,
depart);
230 return arrPos == std::numeric_limits<double>::infinity() ? -NUMERICAL_EPS :
arrPos;
258 const std::vector<double>& _exitTimes,
259 double departPos = std::numeric_limits<double>::infinity(),
260 double arrivalPos = std::numeric_limits<double>::infinity(),
261 const std::string& _destStop =
"")
264 const double departPos,
const double arrivalPos,
const std::string& _destStop)
272 return edges.front();
278 return arr == std::numeric_limits<double>::infinity() ? 0 :
arr;
303 const double departPos,
const std::string& _stopOrigin,
const double arrivalPos,
const std::string& _stopDest,
double _walkFactor,
const std::string& _group) :
311 delete v->getRouteDefinition();
341 return dep == std::numeric_limits<double>::infinity() && replaceDefault ? 0 :
dep;
344 return arr == std::numeric_limits<double>::infinity() && replaceDefault ? 0 :
arr;
350 modes |= additionalModes;
373 delete (*it)->getRouteDefinition();
420 return myPlan.front()->getOrigin();
425 const bool removeLoops,
MsgHandler* errorHandler);
446 const PersonTrip*
const trip,
const ROVehicle*
const veh,
447 std::vector<TripItem*>& resultItems,
MsgHandler*
const errorHandler);
std::vector< const ROEdge * > ConstROEdgeVector
long long int SVCPermissions
bitset where each bit declares whether a certain SVC may use this edge/lane
@ SVC_PEDESTRIAN
pedestrian
A storage for options typed value containers)
Static storage of an output device and its base (abstract) implementation.
An upper class for objects with additional parameters.
A basic edge for routing applications.
A planItem can be a Trip which contains multiple tripItems.
double getDepartPos(bool replaceDefault=true) const
void saveVehicles(OutputDevice &os, OutputDevice *const typeos, bool asAlternatives, OptionsCont &options) const
double getDestinationPos() const
PersonTrip & operator=(const PersonTrip &src)
Invalidated assignment operator.
const std::string & getStopOrigin() const
const std::string stopDest
SVCPermissions getModes() const
virtual ~PersonTrip()
Destructor.
double walkFactor
walking speed factor
const std::string stopOrigin
const std::string & getStopDest() const
double getWalkFactor() const
std::vector< ROVehicle * > myVehicles
the vehicles which may be used for routing
const ROEdge * getDestination() const
SUMOTime getDuration() const
return duration sum of all trip items
double getArrivalPos(bool replaceDefault=true) const
PersonTrip(const ROEdge *const _from, const ROEdge *const _to, const SVCPermissions modeSet, const double departPos, const std::string &_stopOrigin, const double arrivalPos, const std::string &_stopDest, double _walkFactor, const std::string &_group)
virtual void addTripItem(TripItem *tripIt)
std::vector< ROVehicle * > & getVehicles()
const std::string & getGroup() const
void saveAsXML(OutputDevice &os, const bool extended, const bool asTrip, OptionsCont &options) const
const std::string group
group id for travelling in groups
virtual bool needsRouting() const
const ROEdge * getOrigin() const
PersonTrip(const ROEdge *_to, const std::string _stopDest)
std::vector< TripItem * > myTripItems
the fully specified trips
void setItems(std::vector< TripItem * > &newItems, const ROVehicle *const veh)
void addVehicle(ROVehicle *veh)
void updateModes(SVCPermissions additionalModes)
Every person has a plan comprising of multiple planItems.
virtual double getDestinationPos() const =0
virtual ~PlanItem()
Destructor.
virtual void saveAsXML(OutputDevice &os, const bool extended, const bool asTrip, OptionsCont &options) const =0
virtual const ROEdge * getOrigin() const =0
static const std::string UNDEFINED_STOPPING_PLACE
virtual PlanItem * clone() const =0
virtual bool isStop() const
virtual const ROEdge * getDestination() const =0
virtual bool needsRouting() const
virtual const std::string & getStopDest() const
virtual void saveVehicles(OutputDevice &, OutputDevice *const, bool, OptionsCont &) const
virtual SUMOTime getDuration() const =0
virtual void addTripItem(TripItem *)
virtual SUMOVehicleParameter::Stop * getStopParameters()
A ride is part of a trip, e.g., go from here to here by car or bus.
double getDestinationPos() const
const ROEdge * getDestination() const
const std::string destStop
const std::string intended
const ROEdge * getOrigin() const
Ride(const SUMOTime start, const ROEdge *const _from, const ROEdge *const _to, const std::string &_lines, const std::string &_group, const double cost, const double arrivalPos, const double _length, const std::string &_destStop="", const std::string &_intended="", const SUMOTime _depart=-1)
void saveAsXML(OutputDevice &os, const bool extended, OptionsCont &options) const
Ride & operator=(const Ride &src)
Invalidated assignment operator.
A planItem can be a Stop.
virtual SUMOVehicleParameter::Stop * getStopParameters()
SUMOTime getDuration() const
double getDestinationPos() const
const ROEdge * getDestination() const
Stop(const SUMOVehicleParameter::Stop &stop, const ROEdge *const stopEdge)
void saveAsXML(OutputDevice &os, const bool extended, const bool asTrip, OptionsCont &options) const
SUMOVehicleParameter::Stop stopDesc
const std::string & getStopDest() const
const ROEdge * getOrigin() const
Stop & operator=(const Stop &src)
Invalidated assignment operator.
A TripItem is part of a trip, e.g., go from here to here by car.
SUMOTime getStart() const
virtual TripItem * clone() const =0
TripItem(const SUMOTime start, const double cost)
virtual const ROEdge * getOrigin() const =0
SUMOTime getDuration() const
virtual double getDestinationPos() const =0
virtual void saveAsXML(OutputDevice &os, const bool extended, OptionsCont &options) const =0
virtual const ROEdge * getDestination() const =0
virtual ~TripItem()
Destructor.
A walk is part of a trip, e.g., go from here to here by foot.
const ROEdge * getDestination() const
const ConstROEdgeVector edges
void saveAsXML(OutputDevice &os, const bool extended, OptionsCont &options) const
const ROEdge * getOrigin() const
Walk(const SUMOTime start, const ConstROEdgeVector &edges, const double cost, const double duration, const double speed, const double departPos, const double arrivalPos, const std::string &_destStop)
Walk & operator=(const Walk &src)
Invalidated assignment operator.
double getDestinationPos() const
Walk(const SUMOTime start, const ConstROEdgeVector &_edges, const double cost, const std::vector< double > &_exitTimes, double departPos=std::numeric_limits< double >::infinity(), double arrivalPos=std::numeric_limits< double >::infinity(), const std::string &_destStop="")
const std::vector< double > exitTimes
const std::string destStop
A person as used by router.
virtual ~ROPerson()
Destructor.
bool computeIntermodal(SUMOTime time, const RORouterProvider &provider, const PersonTrip *const trip, const ROVehicle *const veh, std::vector< TripItem * > &resultItems, MsgHandler *const errorHandler)
ROPerson & operator=(const ROPerson &src)
Invalidated assignment operator.
static void addTrip(std::vector< PlanItem * > &plan, const std::string &id, const ROEdge *const from, const ROEdge *const to, const SVCPermissions modeSet, const std::string &vTypes, const double departPos, const std::string &stopOrigin, const double arrivalPos, const std::string &busStop, double walkFactor, const std::string &group)
static void addStop(std::vector< PlanItem * > &plan, const SUMOVehicleParameter::Stop &stopPar, const ROEdge *const stopEdge)
static void addRide(std::vector< PlanItem * > &plan, const ROEdge *const from, const ROEdge *const to, const std::string &lines, double arrivalPos, const std::string &destStop, const std::string &group)
void computeRoute(const RORouterProvider &provider, const bool removeLoops, MsgHandler *errorHandler)
static void addWalk(std::vector< PlanItem * > &plan, const ConstROEdgeVector &edges, const double duration, const double speed, const double departPos, const double arrivalPos, const std::string &busStop)
std::vector< PlanItem * > & getPlan()
ROPerson(const ROPerson &src)
Invalidated copy constructor.
const ROEdge * getDepartEdge() const
Returns the first edge the person takes.
void saveAsXML(OutputDevice &os, OutputDevice *const typeos, bool asAlternatives, OptionsCont &options) const
Saves the complete person description.
std::vector< PlanItem * > myPlan
The plan of the person.
A routable thing such as a vehicle or person.
A vehicle as used by router.
Structure representing possible vehicle parameter.
Definition of vehicle stop (position and duration)
double startPos
The stopping position start.
double endPos
The stopping position end.
std::string busstop
(Optional) bus stop if one is assigned to the stop
SUMOTime duration
The stopping duration.
Structure representing possible vehicle parameter.