]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_spanningtree/commands.h
m_spanningtree Ignore incoming BURST command in CONNECTED state
[user/henk/code/inspircd.git] / src / modules / m_spanningtree / commands.h
index d901d69e0dc027dc4b6da2483cec34dd600fcf75..feecc7dd2b5621aa7f48765f836f361b88249403 100644 (file)
@@ -21,6 +21,7 @@
 
 #include "servercommand.h"
 #include "commandbuilder.h"
+#include "remoteuser.h"
 
 /** Handle /RCONNECT
  */
@@ -114,6 +115,7 @@ class CommandOpertype : public UserOnlyServerCommand<CommandOpertype>
 };
 
 class TreeSocket;
+class FwdFJoinBuilder;
 class CommandFJoin : public ServerCommand
 {
        /** Remove all modes from a channel, including statusmodes (+qaovh etc), simplemodes, parameter modes.
@@ -129,10 +131,11 @@ class CommandFJoin : public ServerCommand
         * @param newname The new name of the channel; must be the same or a case change of the current name
         */
        static void LowerTS(Channel* chan, time_t TS, const std::string& newname);
-       void ProcessModeUUIDPair(const std::string& item, TreeServer* sourceserver, Channel* chan, Modes::ChangeList* modechangelist);
+       void ProcessModeUUIDPair(const std::string& item, TreeServer* sourceserver, Channel* chan, Modes::ChangeList* modechangelist, FwdFJoinBuilder& fwdfjoin);
  public:
        CommandFJoin(Module* Creator) : ServerCommand(Creator, "FJOIN", 3) { }
        CmdResult Handle(User* user, std::vector<std::string>& params);
+       RouteDescriptor GetRouting(User* user, const std::vector<std::string>& parameters) { return ROUTE_LOCALONLY; }
 
        class Builder : public CmdBuilder
        {
@@ -140,7 +143,7 @@ class CommandFJoin : public ServerCommand
                 * a message or not
                 */
                static const size_t membid_max_digits = 20;
-               static const size_t maxline = 480;
+               static const size_t maxline = 510;
                std::string::size_type pos;
 
        protected:
@@ -295,14 +298,6 @@ class CommandPong : public ServerOnlyServerCommand<CommandPong>
        RouteDescriptor GetRouting(User* user, const std::vector<std::string>& parameters) { return ROUTE_UNICAST(parameters[0]); }
 };
 
-class CommandPush : public ServerCommand
-{
- public:
-       CommandPush(Module* Creator) : ServerCommand(Creator, "PUSH", 2) { }
-       CmdResult Handle(User* user, std::vector<std::string>& parameters);
-       RouteDescriptor GetRouting(User* user, const std::vector<std::string>& parameters) { return ROUTE_UNICAST(parameters[0]); }
-};
-
 class CommandSave : public ServerCommand
 {
  public:
@@ -367,6 +362,20 @@ class CommandSInfo : public ServerOnlyServerCommand<CommandSInfo>
        };
 };
 
+class CommandNum : public ServerOnlyServerCommand<CommandNum>
+{
+ public:
+       CommandNum(Module* Creator) : ServerOnlyServerCommand<CommandNum>(Creator, "NUM", 3) { }
+       CmdResult HandleServer(TreeServer* server, std::vector<std::string>& parameters);
+       RouteDescriptor GetRouting(User* user, const std::vector<std::string>& parameters);
+
+       class Builder : public CmdBuilder
+       {
+        public:
+               Builder(SpanningTree::RemoteUser* target, const Numeric::Numeric& numeric);
+       };
+};
+
 class SpanningTreeCommands
 {
  public:
@@ -392,12 +401,12 @@ class SpanningTreeCommands
        CommandNick nick;
        CommandPing ping;
        CommandPong pong;
-       CommandPush push;
        CommandSave save;
        CommandServer server;
        CommandSQuit squit;
        CommandSNONotice snonotice;
        CommandEndBurst endburst;
        CommandSInfo sinfo;
+       CommandNum num;
        SpanningTreeCommands(ModuleSpanningTree* module);
 };