15 #include <QSharedData> 21 #include "QXmppConstants_p.h" 22 #include "QXmppElement.h" 23 #include "QXmppNonza.h" 25 #include <QXmlStreamWriter> 28 class QXmppExtendedAddressPrivate;
66 QString description()
const;
67 void setDescription(
const QString &description);
70 void setJid(
const QString &jid);
73 void setType(
const QString &type);
75 bool isDelivered()
const;
76 void setDelivered(
bool);
81 static constexpr std::tuple XmlTag = { u
"address", QXmpp::Private::ns_extended_addressing };
82 void parse(
const QDomElement &element);
83 void toXml(QXmlStreamWriter *writer)
const;
87 QSharedDataPointer<QXmppExtendedAddressPrivate> d;
90 class QXmppStanzaPrivate;
91 class QXmppStanzaErrorPrivate;
141 #if QXMPP_DEPRECATED_SINCE(1, 3) 142 PaymentRequired Q_DECL_ENUMERATOR_DEPRECATED_X(
"The <payment-required/> error was removed in RFC6120"),
146 RecipientUnavailable = 12,
162 Error(Type type, Condition cond,
const QString &text = QString());
163 Error(
const QString &type,
const QString &cond,
const QString &text = QString());
165 Error(QSharedDataPointer<QXmppStanzaErrorPrivate> d);
173 void setCode(
int code);
175 QString text()
const;
176 void setText(
const QString &text);
178 Condition condition()
const;
179 void setCondition(Condition cond);
182 void setType(Type type);
185 void setBy(
const QString &by);
187 QString redirectionUri()
const;
188 void setRedirectionUri(
const QString &redirectionUri);
191 std::optional<QXmpp::JingleErrorCondition> jingleErrorCondition()
const;
192 void setJingleErrorCondition(std::optional<QXmpp::JingleErrorCondition>);
195 bool fileTooLarge()
const;
196 void setFileTooLarge(
bool);
198 qint64 maxFileSize()
const;
199 void setMaxFileSize(qint64);
201 QDateTime retryDate()
const;
202 void setRetryDate(
const QDateTime &);
205 void parse(
const QDomElement &element);
206 void toXml(QXmlStreamWriter *writer)
const;
212 QSharedDataPointer<QXmppStanzaErrorPrivate> d;
224 void setTo(
const QString &);
226 QString
from()
const;
230 void setId(
const QString &);
232 QString
lang()
const;
250 void parse(
const QDomElement &element)
override;
254 void generateAndSetNextId();
258 QSharedDataPointer<QXmppStanzaPrivate> d;
259 friend class TestClient;
265 #endif // QXMPPSTANZA_H The request does not contain a valid schema.
Definition: QXmppStanza.h:130
The error is not temporary.
Definition: QXmppStanza.h:120
The connection to the server could not be established or timed out.
Definition: QXmppStanza.h:150
The given JID is not valid.
Definition: QXmppStanza.h:137
void setId(const QString &)
Definition: QXmppStanza.cpp:760
QString lang() const
Definition: QXmppStanza.cpp:768
QList< QXmppExtendedAddress > extendedAddresses() const
Definition: QXmppStanza.cpp:856
The requesting entity needs to register first.
Definition: QXmppStanza.h:148
void setTo(const QString &)
Definition: QXmppStanza.cpp:724
The QXmppStanza class is the base class for all XMPP stanzas.
Definition: QXmppStanza.h:105
The request should be resent after authentication.
Definition: QXmppStanza.h:140
std::optional< Error > errorOptional() const
Definition: QXmppStanza.cpp:798
QXmppStanza(const QString &from=QString(), const QString &to=QString())
Definition: QXmppStanza.cpp:693
The request conflicts with another.
Definition: QXmppStanza.h:131
JingleErrorCondition
Definition: QXmppStanza.h:37
~QXmppStanza() override
Destroys a QXmppStanza.
virtual void parse(const QDomElement &)=0
QXmppStanza::Error error() const
Definition: QXmppStanza.cpp:788
The requesting entity does not posses the necessary privileges to perform the request.
Definition: QXmppStanza.h:133
An undefined condition was hit.
Definition: QXmppStanza.h:154
The request was unexpected.
Definition: QXmppStanza.h:155
The request needs to be resent after authentication.
Definition: QXmppStanza.h:123
void setExtensions(const QXmppElementList &elements)
Definition: QXmppStanza.cpp:847
The request needs to be changed and resent.
Definition: QXmppStanza.h:122
QString from() const
Definition: QXmppStanza.cpp:732
The remote server could not be found.
Definition: QXmppStanza.h:149
QString id() const
Definition: QXmppStanza.cpp:750
QXmppElementList extensions() const
Definition: QXmppStanza.cpp:837
QString to() const
Definition: QXmppStanza.cpp:714
SceMode
Definition: QXmppGlobal.h:148
The user or server can not be contacted at the address. This is used in combination with a redirectio...
Definition: QXmppStanza.h:134
The service is currently not available.
Definition: QXmppStanza.h:152
The feature is not implemented.
Definition: QXmppStanza.h:132
std::optional< QXmppE2eeMetadata > e2eeMetadata() const
Definition: QXmppStanza.cpp:875
void setError(const QXmppStanza::Error &error)
Definition: QXmppStanza.cpp:811
Condition
A detailed condition of the error.
Definition: QXmppStanza.h:128
The requested item could not be found.
Definition: QXmppStanza.h:136
No entity is allowed to perform the request.
Definition: QXmppStanza.h:139
Processes all known elements.
Definition: QXmppGlobal.h:149
void setFrom(const QString &)
Definition: QXmppStanza.cpp:742
Definition: QXmppNonza.h:13
Represents an extended address as defined by XEP-0033: Extended Stanza Addressing.
Definition: QXmppStanza.h:55
The requester needs to subscribe first.
Definition: QXmppStanza.h:153
The server has expierienced an internal error and can not process the request.
Definition: QXmppStanza.h:135
void setE2eeMetadata(const std::optional< QXmppE2eeMetadata > &e2eeMetadata)
Definition: QXmppStanza.cpp:888
Type
Definition: QXmppStanza.h:118
The requested resource is available elsewhere. This is used in combination with a redirection URI...
Definition: QXmppStanza.h:147
The Error class represents a stanza error.
Definition: QXmppStanza.h:111
The request does not meet the defined critera.
Definition: QXmppStanza.h:138
The recipient lacks system resources to perform the request.
Definition: QXmppStanza.h:151
void setLang(const QString &)
Definition: QXmppStanza.cpp:778
QXmppStanza & operator=(const QXmppStanza &other)
Assigns other to this stanza.
The error was only a warning.
Definition: QXmppStanza.h:121
void setExtendedAddresses(const QList< QXmppExtendedAddress > &extendedAddresses)
Definition: QXmppStanza.cpp:865