CRegistryLoaderComp.h
Go to the documentation of this file.
1 #ifndef icmpstr_CRegistryLoaderComp_included
2 #define icmpstr_CRegistryLoaderComp_included
3 
4 
5 // Qt includes
6 #include <QtCore/QObject>
7 
8 
9 // ACF includes
12 
14 
15 
16 namespace icmpstr
17 {
18 
19 
24  public QObject,
25  public ifile::TFileSerializerComp<ifile::CXmlFileReadArchive, ifile::CXmlFileWriteArchive>
26 {
27 public:
29 
30  I_BEGIN_COMPONENT(CRegistryLoaderComp);
31  I_END_COMPONENT;
32 
33  enum MessageId
34  {
37  };
38 
39  // reimplemented (ifile::IFilePersistence)
40  virtual int LoadFromFile(istd::IChangeable& data, const QString& filePath) const;
41  virtual int SaveToFile(const istd::IChangeable& data, const QString& filePath) const;
42 
43  // reimplemented (ifile::IFileTypeInfo)
44  virtual bool GetFileExtensions(QStringList& result, int flags = -1, bool doAppend = false) const;
45  virtual QString GetTypeDescription(const QString* extensionPtr = NULL) const;
46 
47 protected:
48  QString GetLayoutPath(const QString& registryPath) const;
49 
50  // reimplemented (ifile::TFileSerializerComp)
51  virtual void OnReadError(
52  const ifile::CXmlFileReadArchive& archive,
53  const istd::IChangeable& data,
54  const QString& filePath) const;
55 
56  using QObject::tr;
57 };
58 
59 
60 } // namespace icmpstr
61 
62 
63 #endif // !icmpstr_CRegistryLoaderComp_included
64 
65 
Special registry loader supporting of loading layout data.
virtual void OnReadError(const ifile::CXmlFileReadArchive &archive, const istd::IChangeable &data, const QString &filePath) const
virtual int SaveToFile(const istd::IChangeable &data, const QString &filePath) const
ifile::TFileSerializerComp< ifile::CXmlFileReadArchive, ifile::CXmlFileWriteArchive > BaseClass
virtual bool GetFileExtensions(QStringList &result, int flags=-1, bool doAppend=false) const
virtual int LoadFromFile(istd::IChangeable &data, const QString &filePath) const
virtual QString GetTypeDescription(const QString *extensionPtr=NULL) const
QString GetLayoutPath(const QString &registryPath) const

© 2007-2011 Witold Gantzke and Kirill Lepskiy