eLynx::PluginManager Class Reference
#include <PluginManager.h>
List of all members.
Detailed Description
Base tool class for plugin management.
This is the base class to manage plugin packages and plugins. A PluginManager can only manages plugin packages and plugins of same family type define by an UUID.
Definition at line 40 of file PluginManager.h.
Member Typedef Documentation
List of available plugins with associated package.
Definition at line 181 of file PluginManager.h.
Constructor & Destructor Documentation
eLynx::PluginManager::PluginManager |
( |
const UUID & |
iFamilyType |
) |
|
Default constructor.
- Parameters:
-
| iFamilyType | The UUID that uniquely identity a package family type. While Register is not called the manager can't retrieve any plugin. |
virtual eLynx::PluginManager::~PluginManager |
( |
|
) |
[virtual] |
Destructor. Unregister all packages.
Member Function Documentation
bool eLynx::PluginManager::IsEmpty |
( |
|
) |
const |
Retrieve if at least one plugin is registred.
- Returns:
- true if no plugins are registred, false if at least one plugin is registred.
void eLynx::PluginManager::Register |
( |
const char * |
iprPath, |
|
|
const char * |
iprExt | |
|
) |
| | |
Register all package adhering to the family type, in the given path, with the given file extension.
- Parameters:
-
| iprPath | The base path where to seach packages. |
| iprExt | The extension of the family type package. |
bool eLynx::PluginManager::RegisterFile |
( |
const char * |
iprFilename |
) |
|
Register a plugin package in the managed list.
- Parameters:
-
| iprFilename | The package file to register. |
- Returns:
- true if succeeded, false otherwise.
void eLynx::PluginManager::Unregister |
( |
|
) |
|
Unregister all packages and all plugins.
bool eLynx::PluginManager::Unregister |
( |
const IPluginPackage * |
iprPackage |
) |
|
Unregister a package, and his associated registered plugins.
- Parameters:
-
| iprPackage | The package to unregister. |
- Returns:
- true if succeeded, false otherwise.
bool eLynx::PluginManager::Unregister |
( |
const IPlugin * |
iprPlugin |
) |
|
Unregister a plugin.
- Parameters:
-
| iprPlugin | The plugin to unregister. |
- Returns:
- true if succeeded, false otherwise.
bool eLynx::PluginManager::UnregisterPackage |
( |
const char * |
iprFilename |
) |
|
Unregister a package from his filename.
- Parameters:
-
| iprFilename | The package filename. |
- Returns:
- true if succeeded, false otherwise.
bool eLynx::PluginManager::UnregisterPackage |
( |
const UUID & |
iUUID |
) |
|
Unregister a package from his UUID.
- Parameters:
-
- Returns:
- true if succeeded, false otherwise.
bool eLynx::PluginManager::UnregisterPlugin |
( |
const char * |
iprName |
) |
|
Unregister a plugin from his name.
- Parameters:
-
- Returns:
- true if succeeded, false otherwise.
bool eLynx::PluginManager::UnregisterPlugin |
( |
const UUID & |
iUUID |
) |
|
Unregister a plugin from his UUID.
- Parameters:
-
| iUUID | The UUID that identifie the plugin to unregister. |
- Returns:
- true if succeeded, false otherwise.
size_t eLynx::PluginManager::GetPackageCount |
( |
|
) |
const |
Get the number of registred packages. This is the number of registred dll files.
- Returns:
- The number of registred plugin packages.
const IPluginPackage* eLynx::PluginManager::GetPackage |
( |
size_t |
iIndex = 0 |
) |
const |
Get the package corresponding to the file index.
- Parameters:
-
- Returns:
- A reference pointer on the ith IPluginPackage.
Get the package containing a requested plugin.
- Parameters:
-
| iPlugin | The requested plugin. |
- Returns:
- A reference pointer on the IPluginPackage containing the desired plugin, NULL if the plugin is not registrered.
const IPluginPackage* eLynx::PluginManager::GetPackage |
( |
const UUID & |
iUUID, |
|
|
bool |
ibPlugin = false | |
|
) |
| | const |
Get a package from an UUID.
- Parameters:
-
| iUUID | The UUID of the requested package. |
| ibPlugin | false for PackageID, true for plugin ClassID. |
- Returns:
- A reference pointer on the IPluginPackage containing the desired package, NULL if the package is not registred.
const IPluginPackage* eLynx::PluginManager::GetPackage |
( |
const char * |
iprName, |
|
|
bool |
ibPlugin = true | |
|
) |
| | const |
Get the package from a name.
- Parameters:
-
| iprName | The filename of requested package or the name of the required plugin. |
| ibPlugin | true if iprName is the plugin name, false if it's package filename. |
- Returns:
- A reference pointer on the IPluginPackage containing the desired plugin, NULL if the plugin is not available from loaded packages.
const IPluginPackage* eLynx::PluginManager::GetPackageFromPackageID |
( |
const UUID & |
iUUID |
) |
const |
const IPluginPackage* eLynx::PluginManager::GetPackageFromFilename |
( |
const char * |
iprFilename |
) |
const |
const IPluginPackage* eLynx::PluginManager::GetPackageFromPluginName |
( |
const char * |
iprName |
) |
const |
const IPluginPackage* eLynx::PluginManager::GetPackageFromPluginID |
( |
const UUID & |
iUUID |
) |
const |
size_t eLynx::PluginManager::GetPluginCount |
( |
|
) |
const |
Get the number of registred plugin. This is the total number of registred plugins.
- Returns:
- The number of registred plugin.
const IPlugin* eLynx::PluginManager::GetPlugin |
( |
size_t |
iIndex = 0 |
) |
const |
Get the plugin corresponding to index in registred list.
- Parameters:
-
- Returns:
- A reference pointer on the ith IPlugin.
const IPlugin* eLynx::PluginManager::GetPlugin |
( |
const UUID & |
iUUID |
) |
const |
Get the plugin by is classId.
- Parameters:
-
| iUUID | The UUID of the required plugin. |
- Returns:
- A reference pointer on the desired plugin, NULL if the plugin is not available from loaded packages.
const IPlugin* eLynx::PluginManager::GetPlugin |
( |
const char * |
iprName |
) |
const |
Get the plugin by is description string.
- Parameters:
-
| iprName | The name of the required plugin. |
- Returns:
- A reference pointer on the desired plugin, NULL if the plugin is not available from loaded packages.
static bool eLynx::PluginManager::FileEnumCallback |
( |
const char * |
iprFilename, |
|
|
void * |
iprUserData | |
|
) |
| | [static, protected] |
Member Data Documentation
The documentation for this class was generated from the following file: