|
|||
|
|||
|
Inheritance diagram for ModuleServices:


Public Member Functions | |
| ModuleServices (InspIRCd *Me) | |
| virtual void | OnWhois (User *source, User *dest) |
| Called whenever a /WHOIS is performed on a local user. | |
| virtual void | OnUserPostNick (User *user, const std::string &oldnick) |
| Called after any nickchange, local or remote. | |
| virtual int | OnUserPreMessage (User *user, void *dest, int target_type, std::string &text, char status, CUList &exempt_list) |
| Called whenever a user is about to PRIVMSG A user or a channel, before any processing is done. | |
| virtual int | OnUserPreNotice (User *user, void *dest, int target_type, std::string &text, char status, CUList &exempt_list) |
| Called whenever a user is about to NOTICE A user or a channel, before any processing is done. | |
| virtual int | OnUserPreJoin (User *user, Channel *chan, const char *cname, std::string &privs, const std::string &keygiven) |
| Called whenever a user is about to join a channel, before any processing is done. | |
| virtual | ~ModuleServices () |
| virtual Version | GetVersion () |
| Returns the version number of a Module. | |
Private Attributes | |
| Channel_r * | m1 |
| Channel_R * | m2 |
| Channel_M * | m3 |
| User_r * | m4 |
| User_R * | m5 |
Definition at line 103 of file m_services.cpp.
|
|
Definition at line 112 of file m_services.cpp. References ModeParser::AddMode(), ModuleManager::Attach(), I_OnUserPostNick, I_OnUserPreJoin, I_OnUserPreMessage, I_OnUserPreNotice, I_OnWhois, kludgeme, m1, m2, m3, m4, m5, InspIRCd::Modes, InspIRCd::Modules, and Module::ServerInstance. |
|
|
Definition at line 223 of file m_services.cpp. References ModeParser::DelMode(), kludgeme, m1, m2, m3, m4, m5, InspIRCd::Modes, and Module::ServerInstance. |
|
|
Returns the version number of a Module. The method should return a Version object with its version information assigned via Version::Version Reimplemented from Module. Definition at line 238 of file m_services.cpp. References API_VERSION, VF_COMMON, and VF_VENDOR. |
|
||||||||||||
|
Called after any nickchange, local or remote. This can be used to track users after nickchanges have been applied. Please note that although you can see remote nickchanges through this function, you should NOT make any changes to the User if the user is a remote user as this may cause a desnyc. check user->server before taking any action (including returning nonzero from the method). Because this method is called after the nickchange is taken place, no return values are possible to indicate forbidding of the nick change. Use OnUserPreNick for this.
Reimplemented from Module. Definition at line 144 of file m_services.cpp. References assign(), User::IsModeSet(), kludgeme, User::nick, InspIRCd::SendMode(), and Module::ServerInstance. |
|
||||||||||||||||||||||||
|
Called whenever a user is about to join a channel, before any processing is done. Returning a value of 1 from this function stops the process immediately, causing no output to be sent to the user by the core. If you do this you must produce your own numerics, notices etc. This is useful for modules which may want to mimic +b, +k, +l etc. Returning -1 from this function forces the join to be allowed, bypassing restrictions such as banlists, invite, keys etc. IMPORTANT NOTE! If the user joins a NEW channel which does not exist yet, OnUserPreJoin will be called BEFORE the channel record is created. This will cause Channel* chan to be NULL. There is very little you can do in form of processing on the actual channel record at this point, however the channel NAME will still be passed in char* cname, so that you could for example implement a channel blacklist or whitelist, etc.
Reimplemented from Module. Definition at line 201 of file m_services.cpp. References User::IsModeSet(), Channel::IsModeSet(), Channel::name, User::nick, User::server, Module::ServerInstance, InspIRCd::ULine(), and User::WriteNumeric(). |
|
||||||||||||||||||||||||||||
|
Called whenever a user is about to PRIVMSG A user or a channel, before any processing is done. Returning any nonzero value from this function stops the process immediately, causing no output to be sent to the user by the core. If you do this you must produce your own numerics, notices etc. This is useful for modules which may want to filter or redirect messages. target_type can be one of TYPE_USER or TYPE_CHANNEL. If the target_type value is a user, you must cast dest to a User* otherwise you must cast it to a Channel*, this is the details of where the message is destined to be sent.
Reimplemented from Module. Definition at line 158 of file m_services.cpp. References IS_LOCAL, User::IsModeSet(), Channel::IsModeSet(), Channel::name, User::nick, User::server, Module::ServerInstance, TYPE_CHANNEL, TYPE_USER, InspIRCd::ULine(), and User::WriteNumeric(). Referenced by OnUserPreNotice(). |
|
||||||||||||||||||||||||||||
|
Called whenever a user is about to NOTICE A user or a channel, before any processing is done. Returning any nonzero value from this function stops the process immediately, causing no output to be sent to the user by the core. If you do this you must produce your own numerics, notices etc. This is useful for modules which may want to filter or redirect messages. target_type can be one of TYPE_USER or TYPE_CHANNEL. If the target_type value is a user, you must cast dest to a User* otherwise you must cast it to a Channel*, this is the details of where the message is destined to be sent. You may alter the message text as you wish before relinquishing control to the next module in the chain, and if no other modules block the text this altered form of the text will be sent out to the user and possibly to other servers.
Reimplemented from Module. Definition at line 196 of file m_services.cpp. References OnUserPreMessage(). |
|
||||||||||||
|
Called whenever a /WHOIS is performed on a local user. The source parameter contains the details of the user who issued the WHOIS command, and the dest parameter contains the information of the user they are whoising.
Reimplemented from Module. Definition at line 134 of file m_services.cpp. References User::IsModeSet(), User::nick, InspIRCd::SendWhoisLine(), and Module::ServerInstance. |
|
|
Definition at line 106 of file m_services.cpp. Referenced by ModuleServices(), and ~ModuleServices(). |
|
|
Definition at line 107 of file m_services.cpp. Referenced by ModuleServices(), and ~ModuleServices(). |
|
|
Definition at line 108 of file m_services.cpp. Referenced by ModuleServices(), and ~ModuleServices(). |
|
|
Definition at line 109 of file m_services.cpp. Referenced by ModuleServices(), and ~ModuleServices(). |
|
|
Definition at line 110 of file m_services.cpp. Referenced by ModuleServices(), and ~ModuleServices(). |