RORouteDef.h
Go to the documentation of this file.00001
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 #ifndef RORouteDef_h
00020 #define RORouteDef_h
00021
00022
00023
00024
00025
00026 #ifdef _MSC_VER
00027 #include <windows_config.h>
00028 #else
00029 #include <config.h>
00030 #endif
00031
00032 #include <string>
00033 #include <iostream>
00034 #include <utils/common/Named.h>
00035 #include "ReferencedItem.h"
00036 #include <utils/common/SUMOAbstractRouter.h>
00037 #include <utils/common/RGBColor.h>
00038
00039
00040
00041
00042
00043 class ROEdge;
00044 class RORoute;
00045 class OptionsCont;
00046 class ROVehicle;
00047 class OutputDevice;
00048
00049
00050
00051
00052
00062 class RORouteDef : public ReferencedItem, public Named {
00063 public:
00069 RORouteDef(const std::string &id, const RGBColor * const color) throw();
00070
00071
00073 virtual ~RORouteDef() throw();
00074
00075
00079 virtual RORoute *buildCurrentRoute(SUMOAbstractRouter<ROEdge,ROVehicle> &router, SUMOTime begin,
00080 const ROVehicle &veh) const = 0;
00081
00085 virtual void addAlternative(SUMOAbstractRouter<ROEdge,ROVehicle> &router,
00086 const ROVehicle *const, RORoute *current, SUMOTime begin) = 0;
00087
00089 virtual RORouteDef *copy(const std::string &id) const = 0;
00090
00092 const RGBColor * const getColor() const {
00093 return myColor;
00094 }
00095
00096
00105 virtual OutputDevice &writeXMLDefinition(SUMOAbstractRouter<ROEdge,ROVehicle> &router,
00106 OutputDevice &dev, const ROVehicle * const veh,
00107 bool asAlternatives, bool withExitTimes) const = 0;
00108
00109 protected:
00110 const RGBColor * const copyColorIfGiven() const throw();
00111
00112 protected:
00114 const RGBColor * const myColor;
00115
00116
00117 private:
00119 RORouteDef(const RORouteDef &src);
00120
00122 RORouteDef &operator=(const RORouteDef &src);
00123
00124 };
00125
00126
00127 #endif
00128
00129
00130