summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2010-11-01 17:01:36 (GMT)
committerRemko Tronçon <git@el-tramo.be>2010-11-03 12:17:42 (GMT)
commitf03b5eee1d92f686f4f2ccc8a0b10c18bac05e72 (patch)
treebd4292069a7c184b752c5228dfa4d94d0fad3f56 /Swiften/Elements
parent7e921ec72997493c5ab06cc13d7cf82bb7e8f643 (diff)
downloadswift-contrib-f03b5eee1d92f686f4f2ccc8a0b10c18bac05e72.zip
swift-contrib-f03b5eee1d92f686f4f2ccc8a0b10c18bac05e72.tar.bz2
Centralizing predefined features in DiscoInfo.
Diffstat (limited to 'Swiften/Elements')
-rw-r--r--Swiften/Elements/ChatState.h2
-rw-r--r--Swiften/Elements/DiscoInfo.cpp4
-rw-r--r--Swiften/Elements/DiscoInfo.h3
3 files changed, 8 insertions, 1 deletions
diff --git a/Swiften/Elements/ChatState.h b/Swiften/Elements/ChatState.h
index 8a96bf1..8dcf77c 100644
--- a/Swiften/Elements/ChatState.h
+++ b/Swiften/Elements/ChatState.h
@@ -19,7 +19,7 @@ namespace Swift {
ChatStateType getChatState() { return state_; }
void setChatState(ChatStateType state) {state_ = state;}
- static String getFeatureNamespace() {return "http://jabber.org/protocol/chatstates";}
+
private:
ChatStateType state_;
};
diff --git a/Swiften/Elements/DiscoInfo.cpp b/Swiften/Elements/DiscoInfo.cpp
index 7c939f6..276b341 100644
--- a/Swiften/Elements/DiscoInfo.cpp
+++ b/Swiften/Elements/DiscoInfo.cpp
@@ -8,6 +8,10 @@
namespace Swift {
+const String DiscoInfo::ChatStatesFeature = String("http://jabber.org/protocol/chatstates");
+const String DiscoInfo::SecurityLabelsFeature = String("urn:xmpp:sec-label:0");
+
+
bool DiscoInfo::Identity::operator<(const Identity& other) const {
if (category_ == other.category_) {
if (type_ == other.type_) {
diff --git a/Swiften/Elements/DiscoInfo.h b/Swiften/Elements/DiscoInfo.h
index 249f9ac..038a2f1 100644
--- a/Swiften/Elements/DiscoInfo.h
+++ b/Swiften/Elements/DiscoInfo.h
@@ -19,6 +19,9 @@ namespace Swift {
public:
typedef boost::shared_ptr<DiscoInfo> ref;
+ static const String ChatStatesFeature;
+ static const String SecurityLabelsFeature;
+
const static std::string SecurityLabels;
class Identity {
public: