1 #ifndef LIBR2C2_CATALOGUE_H_
2 #define LIBR2C2_CATALOGUE_H_
5 #include <msp/datafile/loader.h>
6 #include "articlenumber.h"
18 class Loader: public Msp::DataFile::BasicLoader<Catalogue>
23 void ballast_profile();
27 void scale(float, float);
29 void track(ArticleNumber);
30 void vehicle(unsigned);
31 void vehicle(ArticleNumber);
34 typedef std::map<ArticleNumber, TrackType *> TrackMap;
35 typedef std::map<ArticleNumber, VehicleType *> VehicleMap;
37 sigc::signal<void, const TrackType &> signal_track_added;
38 sigc::signal<void, const VehicleType &> signal_vehicle_added;
44 Profile ballast_profile;
46 std::string track_technique;
55 float get_scale() const { return scale; }
56 float get_gauge() const { return gauge; }
57 float get_rail_elevation() const;
58 const Profile &get_rail_profile() const { return rail_profile; }
59 const Profile &get_ballast_profile() const { return ballast_profile; }
60 const Profile &get_path_profile() const { return path_profile; }
61 const std::string &get_track_technique() const { return track_technique; }
63 void add_track(TrackType &);
64 const TrackType &get_track(const ArticleNumber &) const;
65 const TrackMap &get_tracks() const { return tracks; }
67 void add_vehicle(VehicleType &);
68 const VehicleType &get_vehicle(const ArticleNumber &) const;
69 const VehicleMap &get_vehicles() const { return vehicles; }
71 Layout &get_layout() { return layout; }