summaryrefslogtreecommitdiff
path: root/include/modules.h
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-04-11 13:08:31 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-04-11 13:08:31 +0000
commitc12034634020cac5c17b6845613c2c168d174d3d (patch)
tree7c2cb55433c3cde9ca6daabb12d6a43f779cd38b /include/modules.h
parentec8a311cccb90f1397dca47c200300678a4e36aa (diff)
Added 'i' and 't' type link datagrams
Fixed /mode #channel +b glitch git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@521 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'include/modules.h')
-rw-r--r--include/modules.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/modules.h b/include/modules.h
index 691e6eda1..91688b622 100644
--- a/include/modules.h
+++ b/include/modules.h
@@ -458,6 +458,19 @@ class Server : public classbase
* Returns true if the literal successfully matches the pattern, false if otherwise.
*/
virtual bool MatchText(std::string sliteral, std::string spattern);
+
+ /** Calls the handler for a command, either implemented by the core or by another module.
+ * You can use this function to trigger other commands in the ircd, such as PRIVMSG, JOIN,
+ * KICK etc, or even as a method of callback. By defining command names that are untypeable
+ * for users on irc (e.g. those which contain a \r or \n) you may use them as callback identifiers.
+ * The first parameter to this method is the name of the command handler you wish to call, e.g.
+ * PRIVMSG. This will be a command handler previously registered by the core or wih AddCommand().
+ * The second parameter is an array of parameters, and the third parameter is a count of parameters
+ * in the array. If you do not pass enough parameters to meet the minimum needed by the handler, the
+ * functiom will silently ignore it. The final parameter is the user executing the command handler,
+ * used for privilage checks, etc.
+ */
+ virtual void CallCommandHandler(std::string commandname, char** parameters, int pcnt, userrec* user);
};
/** Allows reading of values from configuration files