StelModuleMgr Class Reference
Manage a collection of StelModules including both core and plugin modules.
More...
#include <StelModuleMgr.hpp>
List of all members.
Detailed Description
Manage a collection of StelModules including both core and plugin modules.
The order in which some actions like draw or update are called for each module can be retrieved with the getCallOrders() method.
Member Function Documentation
QList<StelModule*> StelModuleMgr::getAllModules |
( |
|
) |
[inline] |
Get the list of all the currently registered modules.
Get the list of modules in the correct order for calling the given action.
StelModule* StelModuleMgr::getModule |
( |
const QString & |
moduleID, |
|
|
bool |
noWarning = false | |
|
) |
| | |
Get the corresponding module or NULL if can't find it.
- Parameters:
-
| moduleID | the QObject name of the module instance, by convention it is equal to the class name. |
| noWarning | if true, don't display any warning if the module is not found. |
Return the list of all the external module found in the modules directories.
StelModule* StelModuleMgr::loadPlugin |
( |
const QString & |
moduleID |
) |
|
Load dynamically a module.
- Parameters:
-
| moduleID | the name of the module = name of the dynamic library file without extension (e.g "mymodule" for mymodule.so or mymodule.dll) |
- Returns:
- the loaded module or NULL in case of error. The returned Stelmodule still needs to be initialized
void StelModuleMgr::registerModule |
( |
StelModule * |
m, |
|
|
bool |
generateCallingLists = false | |
|
) |
| | |
Register a new StelModule to the list The module is later referenced by its QObject name.
void StelModuleMgr::setPluginLoadAtStartup |
( |
const QString & |
key, |
|
|
bool |
b | |
|
) |
| | |
Define whether a plugin should be loaded at startup.
- Parameters:
-
void StelModuleMgr::unloadAllPlugins |
( |
|
) |
|
void StelModuleMgr::unloadModule |
( |
const QString & |
moduleID, |
|
|
bool |
alsoDelete = true | |
|
) |
| | |
Unregister and delete a StelModule.
The program will hang if other modules depend on the removed one
- Parameters:
-
| moduleID | the unique ID of the module, by convention equal to the class name |
| alsoDelete | if true also delete the StelModule instance, otherwise it has to be deleted by external code. |
void StelModuleMgr::update |
( |
|
) |
|
Regenerate calling lists if necessary.