CClipboardSerializerComp.h
Go to the documentation of this file.
1 #ifndef iqt_CClipboardSerializerComp_included
2 #define iqt_CClipboardSerializerComp_included
3 
4 
5 // ACF includes
6 #include <iser/IVersionInfo.h>
8 #include <ilog/TLoggerCompWrap.h>
9 #include <iqt/iqt.h>
10 
11 
12 namespace iqt
13 {
14 
15 
23  virtual public ifile::IFilePersistence
24 {
25 public:
27 
28  I_BEGIN_COMPONENT(CClipboardSerializerComp);
29  I_REGISTER_INTERFACE(ifile::IFilePersistence);
30  I_ASSIGN(m_versionInfoCompPtr, "VersionInfo", "Provide information about archive versions", false, "VersionInfo");
31  I_ASSIGN(m_mimeTypeAttrPtr, "MimeType", "Describe clipboard type", true, "acf/generic");
32  I_END_COMPONENT;
33 
34  // reimplemented (ifile::IFilePersistence)
35  virtual bool IsOperationSupported(
36  const istd::IChangeable* dataObjectPtr,
37  const QString* filePathPtr = NULL,
38  int flags = -1,
39  bool beQuiet = true) const;
40  virtual int LoadFromFile(
41  istd::IChangeable& data,
42  const QString& filePath = QString(),
43  ibase::IProgressManager* progressManagerPtr = NULL) const;
44  virtual int SaveToFile(
45  const istd::IChangeable& data,
46  const QString& filePath = QString(),
47  ibase::IProgressManager* progressManagerPtr = NULL) const;
48 
49  // reimplemented (ifile::IFileTypeInfo)
50  virtual bool GetFileExtensions(QStringList& result, const istd::IChangeable* dataObjectPtr = NULL, int flags = -1, bool doAppend = false) const;
51  virtual QString GetTypeDescription(const QString* extensionPtr = NULL) const;
52 
53 private:
54  I_REF(iser::IVersionInfo, m_versionInfoCompPtr);
55  I_ATTR(QString, m_mimeTypeAttrPtr);
56 };
57 
58 
59 
60 } // namespace iqt
61 
62 
63 #endif // !iqt_CClipboardSerializerComp_included
64 
65 
virtual bool GetFileExtensions(QStringList &result, const istd::IChangeable *dataObjectPtr=NULL, int flags=-1, bool doAppend=false) const
Get file extensions supported by this loader.
Provides access to version information.
Definition: IVersionInfo.h:22
A clipboard serializer component.
Wrapper provider of log-functionality for component based implementations.
Common interface for data model objects, which can be changed.
Definition: IChangeable.h:24
virtual int LoadFromFile(istd::IChangeable &data, const QString &filePath=QString(), ibase::IProgressManager *progressManagerPtr=NULL) const
This function loads data data from file filePath.
ilog::CLoggerComponentBase BaseClass
#define NULL
Definition: istd.h:64
virtual int SaveToFile(const istd::IChangeable &data, const QString &filePath=QString(), ibase::IProgressManager *progressManagerPtr=NULL) const
This function saves data data to file filePath.
virtual bool IsOperationSupported(const istd::IChangeable *dataObjectPtr, const QString *filePathPtr=NULL, int flags=-1, bool beQuiet=true) const
Returns true if object dataObject can be loaded/saved.
Interface providing loading and saving of data objects.
virtual QString GetTypeDescription(const QString *extensionPtr=NULL) const
Get description of object type associated with single extension.
Consume information about progress of some process.

© 2007-2017 Witold Gantzke and Kirill Lepskiy