From 700a6c7bc39aa48af5037ecbb9778b20fb6f87df Mon Sep 17 00:00:00 2001 From: Florent Le Coz Date: Thu, 3 Dec 2015 21:09:26 +0100 Subject: JID class provides bare() and full() methods --- louloulibs/xmpp/jid.hpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'louloulibs') diff --git a/louloulibs/xmpp/jid.hpp b/louloulibs/xmpp/jid.hpp index b6975a2..e2ee586 100644 --- a/louloulibs/xmpp/jid.hpp +++ b/louloulibs/xmpp/jid.hpp @@ -15,6 +15,15 @@ public: std::string local; std::string resource; + std::string bare() const + { + return this->local + "@" + this->domain; + } + std::string full() const + { + return this->local + "@" + this->domain + "/" + this->resource; + } + private: Jid(const Jid&) = delete; Jid(Jid&&) = delete; -- cgit v1.2.3