summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTarun Gupta <tarun1995gupta@gmail.com>2017-06-26 13:18:09 (GMT)
committerTobias Markmann <tm@ayena.de>2017-07-14 13:19:16 (GMT)
commitf21c9448c5187493fd08574962d88c2db1405512 (patch)
treed8facf4bed5c792833719a1685084b8b4a676d87 /Swiften/Elements
parent0b4aaa1def9625ca3b4ddf869c988a68483135f8 (diff)
downloadswift-f21c9448c5187493fd08574962d88c2db1405512.zip
swift-f21c9448c5187493fd08574962d88c2db1405512.tar.bz2
Add MIXRegisterNick Element, its Parser and Serializer
License: This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details. Test-Information: Added tests for MIXRegisterNick Parser and Serializer based on examples in XEP 0369, which passes. Tested on Ubuntu 16.04 LTS. Change-Id: I80796db9d540c58296afa3454f29e1fb81d04615
Diffstat (limited to 'Swiften/Elements')
-rw-r--r--Swiften/Elements/MIXRegisterNick.h35
1 files changed, 35 insertions, 0 deletions
diff --git a/Swiften/Elements/MIXRegisterNick.h b/Swiften/Elements/MIXRegisterNick.h
new file mode 100644
index 0000000..3bd8c4a
--- /dev/null
+++ b/Swiften/Elements/MIXRegisterNick.h
@@ -0,0 +1,35 @@
+/*
+ * Copyright (c) 2017 Tarun Gupta
+ * Licensed under the simplified BSD license.
+ * See Documentation/Licenses/BSD-simplified.txt for more information.
+ */
+
+#pragma once
+
+#include <memory>
+#include <string>
+
+#include <Swiften/Base/API.h>
+#include <Swiften/Elements/Payload.h>
+
+namespace Swift {
+ class SWIFTEN_API MIXRegisterNick : public Payload {
+ public:
+ using ref = std::shared_ptr<MIXRegisterNick>;
+
+ public:
+
+ MIXRegisterNick() {}
+
+ const std::string& getNick() const {
+ return nick_;
+ }
+
+ void setNick(const std::string& nick) {
+ nick_ = nick;
+ }
+
+ private:
+ std::string nick_;
+ };
+}