SUMO - Simulation of Urban MObility
GNERerouterInterval.h
Go to the documentation of this file.
1 /****************************************************************************/
8 /****************************************************************************/
9 // SUMO, Simulation of Urban MObility; see http://sumo.dlr.de/
10 // Copyright (C) 2001-2017 DLR (http://www.dlr.de/) and contributors
11 /****************************************************************************/
12 //
13 // This file is part of SUMO.
14 // SUMO is free software; you can redistribute it and/or modify
15 // it under the terms of the GNU General Public License as published by
16 // the Free Software Foundation; either version 3 of the License, or
17 // (at your option) any later version.
18 //
19 /****************************************************************************/
20 #ifndef GNERerouterInterval_h
21 #define GNERerouterInterval_h
22 
23 
24 // ===========================================================================
25 // included modules
26 // ===========================================================================
27 #ifdef _MSC_VER
28 #include <windows_config.h>
29 #else
30 #include <config.h>
31 #endif
32 
33 #include <vector>
36 #include "GNERerouter.h"
37 
38 #include "GNEClosingLaneReroute.h"
39 #include "GNEClosingReroute.h"
40 #include "GNEDestProbReroute.h"
41 #include "GNERouteProbReroute.h"
42 
43 // ===========================================================================
44 // class definitions
45 // ===========================================================================
51 public:
53  GNERerouterInterval(GNERerouter* rerouterParent, double begin, double end);
54 
57 
62 
67 
72 
77 
82 
87 
92 
97 
100 
102  SumoXMLTag getTag() const;
103 
105  double getBegin() const;
106 
108  double getEnd() const;
109 
111  void setBegin(double begin);
112 
114  void setEnd(double end);
115 
117  const std::vector<GNEClosingLaneReroute>& getClosingLaneReroutes() const;
118 
120  const std::vector<GNEClosingReroute>& getClosingReroutes() const;
121 
123  const std::vector<GNEDestProbReroute>& getDestProbReroutes() const;
124 
126  const std::vector<GNERouteProbReroute>& getRouteProbReroutes() const;
127 
129  void setClosingLaneReroutes(const std::vector<GNEClosingLaneReroute>& closingLaneReroutes);
130 
132  void setClosingReroutes(const std::vector<GNEClosingReroute>& closingReroutes);
133 
135  void setDestProbReroutes(const std::vector<GNEDestProbReroute>& destProbReroutes);
136 
138  void setRouteProbReroutes(const std::vector<GNERouteProbReroute>& rerouteProbabilityReroutes);
139 
141  GNERerouterInterval& operator=(const GNERerouterInterval& rerouterInterval);
142 
144  bool operator==(const GNERerouterInterval& rerouterInterval) const;
145 
147  bool operator>(const GNERerouterInterval& rerouterInterval) const;
148 
150  bool operator>=(const GNERerouterInterval& rerouterInterval) const;
151 
153  bool operator<(const GNERerouterInterval& rerouterInterval) const;
154 
156  bool operator<=(const GNERerouterInterval& rerouterInterval) const;
157 
158 protected:
161 
163  double myBegin;
164 
166  double myEnd;
167 
170 
172  std::vector<GNEClosingLaneReroute> myClosingLaneReroutes;
173 
175  std::vector<GNEClosingReroute> myClosingReroutes;
176 
178  std::vector<GNEDestProbReroute> myDestProbReroutes;
179 
181  std::vector<GNERouteProbReroute> myRouteProbReroutes;
182 };
183 
184 #endif
185 
186 /****************************************************************************/
SumoXMLTag
Numbers representing SUMO-XML - element names.
bool operator==(const GNERerouterInterval &rerouterInterval) const
overload operator =
bool operator<(const GNERerouterInterval &rerouterInterval) const
overload operator <
double getBegin() const
get begin time
const std::vector< GNEClosingReroute > & getClosingReroutes() const
get closing reroutes
bool operator>=(const GNERerouterInterval &rerouterInterval) const
overload operator >=
std::vector< GNEClosingReroute > myClosingReroutes
vector with the closingReroutes
GNERerouterInterval(GNERerouter *rerouterParent, double begin, double end)
constructor
void setBegin(double begin)
set begin time
std::vector< GNEClosingLaneReroute > myClosingLaneReroutes
vector with the closingLaneReroutes
void setClosingLaneReroutes(const std::vector< GNEClosingLaneReroute > &closingLaneReroutes)
set closing reroutes
bool removeClosingLaneReroutes(const GNEClosingLaneReroute &clr)
remove a previously inserted closing reroute
GNERerouterInterval & operator=(const GNERerouterInterval &rerouterInterval)
overload operator =
const std::vector< GNEDestProbReroute > & getDestProbReroutes() const
get destiny probability reroutes
bool removeClosingReroutes(const GNEClosingReroute &cr)
remove a previously inserted closing reroute
bool insertDestProbReroutes(const GNEDestProbReroute &dpr)
insert destiny probability reroute
const std::vector< GNEClosingLaneReroute > & getClosingLaneReroutes() const
get closing reroutes
bool insertClosinLanegReroutes(const GNEClosingLaneReroute &clr)
insert a new closing lane reroute
bool insertClosingReroutes(const GNEClosingReroute &cr)
insert a new closing lane reroute
void setRouteProbReroutes(const std::vector< GNERouteProbReroute > &rerouteProbabilityReroutes)
set reoute probability reroutes
SumoXMLTag getTag() const
get tag
std::vector< GNEDestProbReroute > myDestProbReroutes
vector with the destProbReroutes
double myBegin
begin timeStep
GNERerouter * getRerouterParent() const
get rerouter parent
double myEnd
end timeStep
std::vector< GNERouteProbReroute > myRouteProbReroutes
vector with the routeProbReroutes
bool removeRouteProbReroute(const GNERouteProbReroute &rpr)
remove a previously inserted route probability reroute
GNERerouter * myRerouterParent
pointer to rerouter parent
bool operator>(const GNERerouterInterval &rerouterInterval) const
overload operator >
void setEnd(double end)
set end time
bool operator<=(const GNERerouterInterval &rerouterInterval) const
overload operator <=
bool removeDestProbReroutes(const GNEDestProbReroute &dpr)
remove a previously inserted destiny probability reroute
const std::vector< GNERouteProbReroute > & getRouteProbReroutes() const
get reoute probability reroutes
SumoXMLTag myTag
XML Tag of a rerouter interval.
bool insertRouteProbReroute(const GNERouteProbReroute &rpr)
insert route probability reroute
double getEnd() const
get end time
~GNERerouterInterval()
destructor
void setClosingReroutes(const std::vector< GNEClosingReroute > &closingReroutes)
set closing reroutes
void setDestProbReroutes(const std::vector< GNEDestProbReroute > &destProbReroutes)
set destiny probability reroutes