+/* $Id$
+
+This file is part of the MSP Märklin suite
+Copyright © 2006-2008 Mikkosoft Productions, Mikko Rasa
+Distributed under the GPL
+*/
+
#ifndef LIBMARKLIN_CATALOGUE_H_
#define LIBMARKLIN_CATALOGUE_H_
namespace Marklin {
+class LocoType;
class TrackType;
class Catalogue
private:
Catalogue &cat;
+ void locomotive(unsigned);
void track(unsigned);
};
+
private:
std::map<unsigned, TrackType *> tracks;
+ std::map<unsigned, LocoType *> locos;
public:
~Catalogue();
- TrackType &get_track(unsigned);
+ TrackType &get_track(unsigned) const;
const std::map<unsigned, TrackType *> &get_tracks() const { return tracks; }
+ LocoType &get_locomotive(unsigned) const;
+ const std::map<unsigned, LocoType *> &get_locomotives() const { return locos; }
void load(const std::string &);
};