1 #ifndef TORCSERIALISER_H 2 #define TORCSERIALISER_H 13 #define QVARIANT_ERROR QStringLiteral("Error: QVariantList must contain only one variant type") 22 void Serialise (QByteArray &Dest,
const QVariant &Data,
const QString &Type = QString());
26 virtual void Prepare (QByteArray &Dest) = 0;
27 virtual void Begin (QByteArray &Dest) = 0;
28 virtual void AddProperty (QByteArray &Dest,
const QString &Name,
const QVariant &Value) = 0;
29 virtual void End (QByteArray &Dest) = 0;
44 bool Accepts (
const QPair<QString,QString> &MimeType)
const;
45 const QString& Description (
void)
const;
46 QString MimeType (
void)
const;
59 #endif // TORCSERIALISER_H
void Serialise(QByteArray &Dest, const QVariant &Data, const QString &Type=QString())
virtual void Begin(QByteArray &Dest)=0
static TorcSerialiser * GetSerialiser(const QString &MimeType)
virtual void Prepare(QByteArray &Dest)=0
static TorcSerialiserFactory * gTorcSerialiserFactory
virtual void End(QByteArray &Dest)=0
virtual void AddProperty(QByteArray &Dest, const QString &Name, const QVariant &Value)=0
virtual HTTPResponseType ResponseType(void)=0
TorcSerialiserFactory * m_nextTorcSerialiserFactory
virtual ~TorcSerialiser()=default