VR-Forces 4.1.1 Class Documentation
mapReader.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2003 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 /*******************************************************************************
6 ** $RCSfile: mapReader.h,v $ $Revision: 1.10 $ $State: Exp $
7 *******************************************************************************/
8 
11 
12 
13 
14 #ifndef DTMAPREADER_H_
15 #define DTMAPREADER_H_
16 
18 
19 #include <QtCore/QHash>
20 #include <QtCore/QObject>
21 
22 class QString;
23 class DtSymbolDescriptor;
24 class DtMapReader;
25 
26 typedef DtSymbolDescriptor* (*DtSymbolDescriptorParserFcn)(DtMapReader* reader, QString key, void*& usr1, void*& usr2);
27 
32 {
33 public:
36  myParserFcn(orig.myParserFcn) {};
37 
39 
40  virtual DtSymbolDescriptorParserFcn parser();
41  virtual void setParser(DtSymbolDescriptorParserFcn fcn);
42 
43 protected:
45 };
46 
48 {
49  Q_OBJECT
50 
51 public:
52  DtMapReader(DtBaseMapper* mapper);
53  virtual ~DtMapReader();
54 
55  virtual bool load(const QString& filename, bool replace = false) = 0;
56  virtual bool save(const QString& filename) = 0;
57  virtual bool init() = 0;
58 
59  virtual void setMediaMapper(DtBaseMapper* mapper);
60 
61  virtual void addSymbolParser(QString symbol, DtSymbolDescriptorParserFcn fcn);
62  virtual DtSymbolDescriptor* createSymbolDescriptor(QString symbol, QString key,
63  void* usr1, void* usr2);
64 
65  virtual DtBaseMapper* symbolMapper();
66 
67  virtual void setComment(const QString&);
68  virtual const QString& comment() const;
69 
70 protected:
73 
74  QString myComment;
75 
76  QHash<QString, DtSymbolDescriptorCreatorInfo> mySymbolParsers;
77 };
78 
79 typedef DtMapReader* (*DtMapReaderCreatorFcn)(DtBaseMapper* mapper);
80 
81 #endif

Document ID: Generated on Mon Apr 8 19:24:01 EDT 2013 from SVN revision 125877
Copyright © 2005-2013 VT MÄK. All Rights Reserved (www.mak.com)