The InspIRCd Project
Home | Developers | Wiki | Forums | Bug Tracker | SVN | Download
Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

ModuleOperjoin Class Reference

Inheritance diagram for ModuleOperjoin:

Inheritance graph
[legend]
Collaboration diagram for ModuleOperjoin:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 ModuleOperjoin (InspIRCd *Me)
virtual void OnRehash (User *user, const std::string &parameter)
 Called on rehash.
virtual ~ModuleOperjoin ()
virtual Version GetVersion ()
 Returns the version number of a Module.
virtual void OnPostOper (User *user, const std::string &opertype, const std::string &opername)
 Called after a user opers locally.

Private Member Functions

int tokenize (const std::string &str, std::vector< std::string > &tokens)

Private Attributes

std::string operChan
std::vector< std::stringoperChans
std::map< std::string, std::vector<
std::string > > 
operTypeChans
bool override

Detailed Description

Definition at line 18 of file m_operjoin.cpp.


Constructor & Destructor Documentation

ModuleOperjoin::ModuleOperjoin InspIRCd Me  )  [inline]
 

Definition at line 46 of file m_operjoin.cpp.

References ModuleManager::Attach(), I_OnPostOper, I_OnRehash, InspIRCd::Modules, OnRehash(), and Module::ServerInstance.

virtual ModuleOperjoin::~ModuleOperjoin  )  [inline, virtual]
 

Definition at line 79 of file m_operjoin.cpp.


Member Function Documentation

virtual Version ModuleOperjoin::GetVersion  )  [inline, virtual]
 

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 83 of file m_operjoin.cpp.

References API_VERSION, and VF_VENDOR.

virtual void ModuleOperjoin::OnPostOper User user,
const std::string opertype,
const std::string opername
[inline, virtual]
 

Called after a user opers locally.

This is identical to Module::OnOper(), except it is called after OnOper so that other modules can be gauranteed to already have processed the oper-up, for example m_spanningtree has sent out the OPERTYPE, etc.

Parameters:
user The user who is opering up
opername The name of the oper that the user is opering up to. Only valid locally. Empty string otherwise.
opertype The opers type name

Reimplemented from Module.

Definition at line 88 of file m_operjoin.cpp.

References ServerLimits::ChanMax, InspIRCd::Config, IS_LOCAL, InspIRCd::IsChannel, Channel::JoinUser(), ServerConfig::Limits, User::oper, operChans, operTypeChans, override, Module::ServerInstance, and InspIRCd::Time().

virtual void ModuleOperjoin::OnRehash User user,
const std::string parameter
[inline, virtual]
 

Called on rehash.

This method is called prior to a /REHASH or when a SIGHUP is received from the operating system. You should use it to reload any files so that your module keeps in step with the rest of the application. If a parameter is given, the core has done nothing. The module receiving the event can decide if this parameter has any relevence to it.

Parameters:
user The user performing the rehash, if any -- if this is server initiated, the value of this variable will be NULL.
parameter The (optional) parameter given to REHASH from the user.

Reimplemented from Module.

Definition at line 54 of file m_operjoin.cpp.

References conf, ConfigReader::Enumerate(), operChan, operChans, operTypeChans, override, ConfigReader::ReadFlag(), ConfigReader::ReadValue(), Module::ServerInstance, and tokenize().

Referenced by ModuleOperjoin().

int ModuleOperjoin::tokenize const std::string str,
std::vector< std::string > &  tokens
[inline, private]
 

Definition at line 26 of file m_operjoin.cpp.

Referenced by OnRehash().


Member Data Documentation

std::string ModuleOperjoin::operChan [private]
 

Definition at line 21 of file m_operjoin.cpp.

Referenced by OnRehash().

std::vector<std::string> ModuleOperjoin::operChans [private]
 

Definition at line 22 of file m_operjoin.cpp.

Referenced by OnPostOper(), and OnRehash().

std::map<std::string, std::vector<std::string> > ModuleOperjoin::operTypeChans [private]
 

Definition at line 23 of file m_operjoin.cpp.

Referenced by OnPostOper(), and OnRehash().

bool ModuleOperjoin::override [private]
 

Definition at line 24 of file m_operjoin.cpp.

Referenced by OnPostOper(), and OnRehash().


The documentation for this class was generated from the following file: