|
|||
|
|||
|


Public Member Functions | |
| ModuleServicesAccount (InspIRCd *Me) | |
| virtual void | On005Numeric (std::string &t) |
| Called when a 005 numeric is about to be output. | |
| 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 void | OnSyncUserMetaData (User *user, Module *proto, void *opaque, const std::string &extname, bool displayable) |
| virtual void | OnUserQuit (User *user, const std::string &message, const std::string &oper_message) |
| Called when a user quits. | |
| virtual void | OnCleanup (int target_type, void *item) |
| Called before your module is unloaded to clean up Extensibles. | |
| virtual void | OnDecodeMetaData (int target_type, void *target, const std::string &extname, const std::string &extdata) |
| Allows module data, sent via ProtoSendMetaData, to be decoded again by a receiving module. | |
| virtual | ~ModuleServicesAccount () |
| virtual Version | GetVersion () |
| Returns the version number of a Module. | |
Private Attributes | |
| AChannel_R * | m1 |
| AChannel_M * | m2 |
| AUser_R * | m3 |
| Channel_r * | m4 |
| User_r * | m5 |
Definition at line 100 of file m_services_account.cpp.
|
|
Definition at line 108 of file m_services_account.cpp. References ModeParser::AddMode(), ModuleManager::Attach(), I_On005Numeric, I_OnCleanup, I_OnDecodeMetaData, I_OnSyncUserMetaData, I_OnUserPostNick, I_OnUserPreJoin, I_OnUserPreMessage, I_OnUserPreNotice, I_OnUserQuit, I_OnWhois, m1, m2, m3, m4, m5, InspIRCd::Modes, InspIRCd::Modules, and Module::ServerInstance. |
|
|
Definition at line 358 of file m_services_account.cpp. References ModeParser::DelMode(), 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 372 of file m_services_account.cpp. References API_VERSION, VF_COMMON, and VF_VENDOR. |
|
|
Called when a 005 numeric is about to be output. The module should modify the 005 numeric if needed to indicate its features.
Reimplemented from Module. Definition at line 125 of file m_services_account.cpp. References InspIRCd::AddExtBanChar(), and Module::ServerInstance. |
|
||||||||||||
|
Called before your module is unloaded to clean up Extensibles. This method is called once for every user and channel on the network, so that when your module unloads it may clear up any remaining data in the form of Extensibles added using Extensible::Extend(). If the target_type variable is TYPE_USER, then void* item refers to a User*, otherwise it refers to a Channel*.
Reimplemented from Module. Definition at line 294 of file m_services_account.cpp. References Extensible::GetExt(), Extensible::Shrink(), and TYPE_USER. |
|
||||||||||||||||||||
|
Allows module data, sent via ProtoSendMetaData, to be decoded again by a receiving module. Please see src/modules/m_swhois.cpp for a working example of how to use this method call.
Reimplemented from Module. Definition at line 316 of file m_services_account.cpp. References AccountData::account, Extensible::Extend(), Extensible::GetExt(), User::GetFullHost(), IS_LOCAL, User::nick, Event::Send(), Module::ServerInstance, Extensible::Shrink(), trim(), TYPE_USER, AccountData::user, and User::WriteNumeric(). |
|
||||||||||||||||||||||||
|
Reimplemented from Module. Definition at line 261 of file m_services_account.cpp. References Extensible::GetExt(), Module::ProtoSendMetaData(), trim(), and TYPE_USER. |
|
||||||||||||
|
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 149 of file m_services_account.cpp. References assign(), User::IsModeSet(), 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 216 of file m_services_account.cpp. References ERR_BANNEDFROMCHAN, Extensible::GetExt(), IS_LOCAL, Channel::IsExtBanned(), 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 161 of file m_services_account.cpp. References Extensible::GetExt(), IS_LOCAL, Channel::IsExtBanned(), 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 211 of file m_services_account.cpp. References OnUserPreMessage(). |
|
||||||||||||||||
|
Called when a user quits. The details of the exiting user are available to you in the parameter User *user This event is only called when the user is fully registered when they quit. To catch raw disconnections, use the OnUserDisconnect method.
Reimplemented from Module. Definition at line 282 of file m_services_account.cpp. References Extensible::GetExt(), and Extensible::Shrink(). |
|
||||||||||||
|
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 132 of file m_services_account.cpp. References Extensible::GetExt(), User::IsModeSet(), User::nick, InspIRCd::SendWhoisLine(), and Module::ServerInstance. |
|
|
Definition at line 102 of file m_services_account.cpp. Referenced by ModuleServicesAccount(), and ~ModuleServicesAccount(). |
|
|
Definition at line 103 of file m_services_account.cpp. Referenced by ModuleServicesAccount(), and ~ModuleServicesAccount(). |
|
|
Definition at line 104 of file m_services_account.cpp. Referenced by ModuleServicesAccount(), and ~ModuleServicesAccount(). |
|
|
Definition at line 105 of file m_services_account.cpp. Referenced by ModuleServicesAccount(), and ~ModuleServicesAccount(). |
|
|
Definition at line 106 of file m_services_account.cpp. Referenced by ModuleServicesAccount(), and ~ModuleServicesAccount(). |