From 3fef0ed889eecb40b96a597924254560c81d4a09 Mon Sep 17 00:00:00 2001 From: Attila Molnar Date: Sun, 26 Jan 2014 13:12:01 +0100 Subject: Add ProtocolInterface::BroadcastEncap() and infrastructure for manually forwarding ENCAPs --- include/protocol.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'include/protocol.h') diff --git a/include/protocol.h b/include/protocol.h index 4c58c78ba..01eb145f1 100644 --- a/include/protocol.h +++ b/include/protocol.h @@ -68,6 +68,16 @@ class CoreExport ProtocolInterface */ virtual bool SendEncapsulatedData(const std::string& targetmask, const std::string& cmd, const parameterlist& params, User* source = NULL) { return false; } + /** Send an ENCAP message to all servers. + * See the protocol documentation for the purpose of ENCAP. + * @param cmd The ENCAP subcommand + * @param params List of string parameters which are dependant on the subcommand + * @param source The source of the message (prefix), must be a local user or a user behind 'omit' + * or NULL which is equivalent to the local server + * @param omit If non-NULL the message won't be sent in the direction of this server, useful for forwarding messages + */ + virtual void BroadcastEncap(const std::string& cmd, const parameterlist& params, User* source = NULL, User* omit = NULL) { } + /** Send metadata for a channel to other linked servers. * @param chan The channel to send metadata for * @param key The 'key' of the data, e.g. "swhois" for swhois desc on a user -- cgit v1.3.1-10-gc9f91