diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/ctables.h | 15 | ||||
-rw-r--r-- | include/users.h | 22 |
2 files changed, 26 insertions, 11 deletions
diff --git a/include/ctables.h b/include/ctables.h index 80962b67e..4cb530e63 100644 --- a/include/ctables.h +++ b/include/ctables.h @@ -214,6 +214,21 @@ class CoreExport Command : public classbase virtual ~Command(); }; +class LocalUser; +class RemoteUser; +class FakeUser; + +class CoreExport SplitCommand : public Command +{ + public: + SplitCommand(Module* me, const std::string &cmd, int minpara = 0, int maxpara = 0) + : Command(me, cmd, minpara, maxpara) {} + virtual CmdResult Handle(const std::vector<std::string>& parameters, User* user); + virtual CmdResult HandleLocal(const std::vector<std::string>& parameters, LocalUser* user); + virtual CmdResult HandleRemote(const std::vector<std::string>& parameters, RemoteUser* user); + virtual CmdResult HandleServer(const std::vector<std::string>& parameters, FakeUser* user); +}; + /** A hash of commands used by the core */ typedef nspace::hash_map<std::string,Command*> Commandtable; diff --git a/include/users.h b/include/users.h index c60d5f033..fcdc5b374 100644 --- a/include/users.h +++ b/include/users.h @@ -639,11 +639,6 @@ class CoreExport User : public StreamSocket */ void CheckClass(); - /** Use this method to fully connect a user. - * This will send the message of the day, check G/K/E lines, etc. - */ - void FullConnect(); - /** Change this users hash key to a new string. * You should not call this function directly. It is used by the core * to update the users hash entry on a nickchange. @@ -835,12 +830,6 @@ class CoreExport User : public StreamSocket */ ConnectClass *GetClass(); - /** Set the connect class to which this user belongs to. - * @param explicit_name Set this string to tie the user to a specific class name. Otherwise, the class is fitted by checking <connect> tags from the configuration file. - * @return A reference to this user's current connect class. - */ - ConnectClass *SetClass(const std::string &explicit_name = ""); - /** Show the message of the day to this user */ void ShowMOTD(); @@ -890,6 +879,17 @@ class CoreExport LocalUser : public User public: LocalUser(); virtual void SendText(const std::string& line); + + /** Use this method to fully connect a user. + * This will send the message of the day, check G/K/E lines, etc. + */ + void FullConnect(); + + /** Set the connect class to which this user belongs to. + * @param explicit_name Set this string to tie the user to a specific class name. Otherwise, the class is fitted by checking <connect> tags from the configuration file. + * @return A reference to this user's current connect class. + */ + ConnectClass *SetClass(const std::string &explicit_name = ""); }; class CoreExport RemoteUser : public User |