AusweisApp
Lade ...
Suche ...
Keine Treffer
PaosCreator.h
gehe zur Dokumentation dieser Datei
1
9#pragma once
10
11#include "paos/ResponseType.h"
12
13#include <QXmlStreamWriter>
14
15namespace governikus
16{
17
19{
20 Q_DISABLE_COPY(PaosCreator)
21
22 public:
23 enum class Namespace
24 {
26 };
27
28 private:
29 static const QMap<Namespace, QString> mNamespacePrefix;
30 static const QMap<Namespace, QString> mNamespace;
31
32 QByteArray mContent;
33 QString mRelatedMessageId;
34
35 void createEnvelopeElement();
36 void createHeaderElement();
37
38 protected:
39 QXmlStreamWriter mWriter;
40
41 void writeTextElement(const QString& pQualifiedName, const QByteArray& pText);
42 virtual void createBodyElement() = 0;
43
44 void createResultElement(const ResponseType& pResponse);
45
47 virtual ~PaosCreator();
48
49 public:
56 QByteArray marshall();
57
58 void setRelatedMessageId(const QString& pId);
59 [[nodiscard]] static QString getNamespace(Namespace pPrefix);
60 [[nodiscard]] static QString getNamespacePrefix(Namespace pPrefix, const QString& pSuffix = QString());
61 [[nodiscard]] static QString getNamespaceType(Namespace pPrefix, const QString& pType);
62};
63
64} // namespace governikus
Definition: PaosCreator.h:19
void setRelatedMessageId(const QString &pId)
Definition: PaosCreator.cpp:97
QByteArray marshall()
Creates an XML structure of underlying information. Be aware that this method will create the structu...
Definition: PaosCreator.cpp:87
void createResultElement(const ResponseType &pResponse)
Definition: PaosCreator.cpp:177
virtual void createBodyElement()=0
static QString getNamespacePrefix(Namespace pPrefix, const QString &pSuffix=QString())
Definition: PaosCreator.cpp:64
QXmlStreamWriter mWriter
Definition: PaosCreator.h:39
void writeTextElement(const QString &pQualifiedName, const QByteArray &pText)
Definition: PaosCreator.cpp:145
static QString getNamespaceType(Namespace pPrefix, const QString &pType)
Definition: PaosCreator.cpp:56
Namespace
Definition: PaosCreator.h:24
static QString getNamespace(Namespace pPrefix)
Definition: PaosCreator.cpp:50
PaosCreator()
Definition: PaosCreator.cpp:38
Definition: ResponseType.h:22
Implementation of GeneralAuthenticate response APDUs.
Definition: CommandApdu.h:16