00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef SOPRANO_SERIALIZER_H
00022 #define SOPRANO_SERIALIZER_H
00023
00024 #include "plugin.h"
00025 #include "soprano_export.h"
00026 #include "sopranotypes.h"
00027 #include "error.h"
00028
00029 #include <QtCore/QObject>
00030
00031 class QTextStream;
00032
00033
00034 namespace Soprano
00035 {
00036 class StatementIterator;
00037
00065 class SOPRANO_EXPORT Serializer : public Plugin, public Error::ErrorCache
00066 {
00067 public:
00068 virtual ~Serializer();
00069
00077 virtual RdfSerializations supportedSerializations() const = 0;
00078
00087 virtual QStringList supportedUserSerializations() const;
00088
00100 bool supportsSerialization( RdfSerialization s, const QString& userSerialization = QString() ) const;
00101
00114 virtual bool serialize( StatementIterator it, QTextStream& stream, RdfSerialization serialization, const QString& userSerialization = QString() ) const = 0;
00115
00116 protected:
00117 Serializer( const QString& name );
00118
00119 private:
00120 class Private;
00121 Private* const d;
00122 };
00123 }
00124
00125 Q_DECLARE_INTERFACE(Soprano::Serializer, "org.soprano.plugins.Serializer/1.0")
00126
00127 #endif
00128