From eb9a20187098185cc10ad192e91a90dbba12633a Mon Sep 17 00:00:00 2001 From: Florent Le Coz Date: Tue, 27 May 2014 01:01:38 +0200 Subject: Implement the support for adhoc commands MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We have two basic example commands. But it’s not entirely finished because there are some error checks that we don’t do. ref #2521 --- src/xmpp/xmpp_component.hpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/xmpp/xmpp_component.hpp') diff --git a/src/xmpp/xmpp_component.hpp b/src/xmpp/xmpp_component.hpp index d934704..b234d76 100644 --- a/src/xmpp/xmpp_component.hpp +++ b/src/xmpp/xmpp_component.hpp @@ -1,6 +1,7 @@ #ifndef XMPP_COMPONENT_INCLUDED # define XMPP_COMPONENT_INCLUDED +#include #include #include #include @@ -177,6 +178,11 @@ public: * Send a result IQ with the gateway disco informations. */ void send_self_disco_info(const std::string& id, const std::string& jid_to); + /** + * Send the list of all available ad-hoc commands to that JID. The list is + * different depending on what JID made the request. + */ + void send_adhoc_commands_list(const std::string& id, const std::string& requester_jid); /** * Send an iq version request */ @@ -231,6 +237,7 @@ private: static unsigned long current_id; + AdhocCommandsHandler adhoc_commands_handler; XmppComponent(const XmppComponent&) = delete; XmppComponent(XmppComponent&&) = delete; XmppComponent& operator=(const XmppComponent&) = delete; -- cgit v1.2.3