Audacity 3.2.0
Classes | Typedefs | Functions | Variables
ModuleManager.h File Reference
#include "MemoryX.h"
#include <functional>
#include <map>
#include <vector>
#include <wx/string.h>
#include "Identifier.h"
#include "ModuleConstants.h"
Include dependency graph for ModuleManager.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  Module
 
struct  PluginProviderDeleter
 
class  ModuleManager
 
struct  Init
 

Typedefs

using PluginID = wxString
 
typedef int(* fnModuleDispatch) (ModuleDispatchTypes type)
 
using PluginProviderHandle = std::unique_ptr< PluginProvider, PluginProviderDeleter >
 
typedef std::map< wxString, PluginProviderHandlePluginProviderMap
 
using PluginProviderMain = PluginProvider *(*)()
 

Functions

MODULE_MANAGER_API void RegisterProvider (PluginProviderMain rtn)
 
MODULE_MANAGER_API void UnregisterProvider (PluginProviderMain rtn)
 

Variables

static struct Init sInitBuiltinModules
 

Typedef Documentation

◆ fnModuleDispatch

typedef int(* fnModuleDispatch) (ModuleDispatchTypes type)

Definition at line 39 of file ModuleManager.h.

◆ PluginID

using PluginID = wxString

Definition at line 28 of file ModuleManager.h.

◆ PluginProviderHandle

Definition at line 65 of file ModuleManager.h.

◆ PluginProviderMain

Definition at line 144 of file ModuleManager.h.

◆ PluginProviderMap

typedef std::map<wxString, PluginProviderHandle> PluginProviderMap

Definition at line 69 of file ModuleManager.h.

Function Documentation

◆ RegisterProvider()

MODULE_MANAGER_API void RegisterProvider ( PluginProviderMain  rtn)

Definition at line 186 of file ModuleManager.cpp.

187{
188 auto &list = builtinProviderList();
189 if ( pluginProviderMain )
190 list.push_back(pluginProviderMain);
191
192 return;
193}
BuiltinProviderList & builtinProviderList()

References anonymous_namespace{ModuleManager.cpp}::builtinProviderList().

Referenced by Init::Init().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ UnregisterProvider()

MODULE_MANAGER_API void UnregisterProvider ( PluginProviderMain  rtn)

Definition at line 195 of file ModuleManager.cpp.

196{
197 auto &list = builtinProviderList();
198 auto end = list.end(), iter = std::find(list.begin(), end, pluginProviderMain);
199 if (iter != end)
200 list.erase(iter);
201}
auto end(const Ptr< Type, BaseDeleter > &p)
Enables range-for.
Definition: PackedArray.h:159

References anonymous_namespace{ModuleManager.cpp}::builtinProviderList(), and PackedArray::end().

Here is the call graph for this function:

Variable Documentation

◆ sInitBuiltinModules

struct Init sInitBuiltinModules
static