diff options
| author | 2007-11-04 19:28:22 +0000 | |
|---|---|---|
| committer | 2007-11-04 19:28:22 +0000 | |
| commit | e1efa862f373aacefa027f346c0976f802818727 (patch) | |
| tree | 2fc86b62ff306f219c36af763bcc587c43baced7 /src/modules.cpp | |
| parent | Remove our vectors of Module*/ircd_module*, replace with a map of std::pair<i... (diff) | |
Not yet tested: remove last vestiges of modules[] and module_names[] arrays.
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8514 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules.cpp')
| -rw-r--r-- | src/modules.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/modules.cpp b/src/modules.cpp index 7bc9f94c4..29c185f1a 100644 --- a/src/modules.cpp +++ b/src/modules.cpp @@ -785,6 +785,15 @@ Module* ModuleManager::Find(const std::string &name) return modfind->second.second; } +const std::vector<std::string> ModuleManager::GetAllModuleNames(int filter) +{ + std::vector<std::string> retval; + for (std::map<std::string, std::pair<ircd_module*, Module*> >::iterator x = Modules.begin(); x != Modules.end(); ++x) + if (!filter || (x->second.second->GetVersion().Flags & filter)) + retval.push_back(x->first); + return retval; +} + ConfigReader::ConfigReader(InspIRCd* Instance) : ServerInstance(Instance) { /* Is there any reason to load the entire config file again here? |
