aboutsummaryrefslogtreecommitdiff
path: root/source/QXmppStanza.h
diff options
context:
space:
mode:
authorJeremy Lainé <jeremy.laine@m4x.org>2010-03-04 09:15:34 +0000
committerJeremy Lainé <jeremy.laine@m4x.org>2010-03-04 09:15:34 +0000
commit628112acd69f4bf794c4d417d2c3bced1712cba3 (patch)
tree05c03373ad3ca732cd4444a9d46f3f3c935f7f2b /source/QXmppStanza.h
parentc2a7a03e30d1d99e57172c94c106fdc842dfbf25 (diff)
downloadqxmpp-628112acd69f4bf794c4d417d2c3bced1712cba3.tar.gz
make error parsing private to QXmppStanza::Error
Diffstat (limited to 'source/QXmppStanza.h')
-rw-r--r--source/QXmppStanza.h33
1 files changed, 24 insertions, 9 deletions
diff --git a/source/QXmppStanza.h b/source/QXmppStanza.h
index 38b5d1c6..8eb8dd7b 100644
--- a/source/QXmppStanza.h
+++ b/source/QXmppStanza.h
@@ -80,21 +80,37 @@ public:
Error(Type type, Condition cond, const QString& text="");
Error(const QString& type, const QString& cond, const QString& text="");
+ int code() const;
void setCode(int code);
+
+ QString text() const;
void setText(const QString& text);
+
+ Condition condition() const;
void setCondition(Condition cond);
- void setConditionFromStr(const QString& cond);
+
void setType(Type type);
- void setTypeFromStr(const QString& type);
- int getCode() const;
- QString getText() const;
- Condition getCondition() const;
- Type getType() const;
- void toXml( QXmlStreamWriter *writer ) const;
+ Type type() const;
+
+ // FIXME : remove this once is gone
+ bool isValid();
+
+ void parse(const QDomElement &element);
+ void toXml(QXmlStreamWriter *writer) const;
+
+ // deprecated accessors, use the form without "get" instead
+ int Q_DECL_DEPRECATED getCode() const;
+ QString Q_DECL_DEPRECATED getText() const;
+ Condition Q_DECL_DEPRECATED getCondition() const;
+ Type Q_DECL_DEPRECATED getType() const;
+
+ private:
QString getConditionStr() const;
+ void setConditionFromStr(const QString& cond);
+
QString getTypeStr() const;
+ void setTypeFromStr(const QString& type);
- private:
int m_code;
Type m_type;
Condition m_condition;
@@ -135,7 +151,6 @@ public:
protected:
void generateAndSetNextId();
void parse(const QDomElement &element);
- static QXmppStanza::Error parseError(const QDomElement&);
private:
static uint s_uniqeIdNo;