diff --git a/include/Swiften/Elements/PubSubSubscriptionPayload.h b/include/Swiften/Elements/PubSubSubscriptionPayload.h new file mode 100644 index 0000000000000000000000000000000000000000..c404e6fff72248df5e01cae382088da4145ffa6a --- /dev/null +++ b/include/Swiften/Elements/PubSubSubscriptionPayload.h @@ -0,0 +1,60 @@ +/* + * Copyright (c) 2011 Jan Kaluza + * Licensed under the Simplified BSD license. + * See Documentation/Licenses/BSD-simplified.txt for more information. + */ + +#pragma once + +#include + +#include +#include +#include + +namespace Swift { + class PubSubSubscriptionPayload : public Payload { + public: + enum Type { None, Pending, Subscribed, Unconfigured }; + + PubSubSubscriptionPayload(const JID &jid = JID(), const std::string &node = ""); + + void setJID(const JID &jid) { + this->jid = jid; + } + + const JID &getJID() const { + return jid; + } + + void setNode(const std::string &node) { + this->node = node; + } + + const std::string &getNode() const { + return node; + } + + void setId(const std::string &id) { + this->id = id; + } + + const std::string &getId() const { + return id; + } + + void setType(const Type &type) { + this->type = type; + } + + const Type &getType() const { + return type; + } + + private: + JID jid; + std::string node; + std::string id; + Type type; + }; +}