3 This file is part of the MSP Märklin suite
4 Copyright © 2010 Mikkosoft Productions, Mikko Rasa
5 Distributed under the GPL
8 #ifndef LIBMARKLIN_VEHICLETYPE_H_
9 #define LIBMARKLIN_VEHICLETYPE_H_
11 #include <msp/datafile/objectloader.h>
18 class Loader: public Msp::DataFile::ObjectLoader<VehicleType>
21 Loader(VehicleType &);
25 void function(unsigned, const std::string &);
33 class Loader: public Msp::DataFile::ObjectLoader<Axle>
39 void wheel_diameter(float);
51 class Loader: public Msp::DataFile::ObjectLoader<Bogie>
61 std::vector<Axle> axles;
72 std::map<unsigned, std::string> functions;
76 std::vector<Axle> axles;
77 std::vector<Bogie> bogies;
81 VehicleType(unsigned);
83 unsigned get_article_number() const { return art_nr; }
84 const std::string &get_name() const { return name; }
85 bool is_locomotive() const { return locomotive; }
86 unsigned get_max_function() const;
87 const std::map<unsigned, std::string> &get_functions() const { return functions; }
88 float get_length() const { return length; }
89 float get_width() const { return width; }
90 float get_height() const { return height; }
91 const std::vector<Axle> &get_axles() const { return axles; }
92 const std::vector<Bogie> &get_bogies() const { return bogies; }
93 const std::string &get_object() const { return object; }
96 } // namespace Marklin