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
00049 class SOPRANO_EXPORT Serializer : public Plugin, public Error::ErrorCache
00050 {
00051 public:
00052 virtual ~Serializer();
00053
00061 virtual RdfSerializations supportedSerializations() const = 0;
00062
00071 virtual QStringList supportedUserSerializations() const;
00072
00084 bool supportsSerialization( RdfSerialization s, const QString& userSerialization = QString() ) const;
00085
00098 virtual bool serialize( StatementIterator it, QTextStream& stream, RdfSerialization serialization, const QString& userSerialization = QString() ) const = 0;
00099
00100 protected:
00101 Serializer( const QString& name );
00102
00103 private:
00104 class Private;
00105 Private* const d;
00106 };
00107 }
00108
00109 Q_DECLARE_INTERFACE(Soprano::Serializer, "org.soprano.plugins.Serializer/1.0")
00110
00111 #endif
00112