This class usually is used as a base class for types that need to manage simple plug-ins. Within ALib itself, for example classes Configuration and Compiler inherit from this class.
Plug-ins are organized with a prioritization. This means, that plug-ins which are inserted with a higher priority are 'asked' first, and those with a lower value become 'asked' only if higher prioritized plug-ins did not answer.
However, a derived class can deviate from this behavior. Using the typical ALib class design, all internal fields are protected
, hence freely accessible by derived classes.
TPlugin | The plug-in type that this class manages. This type is publicly exposed as PluginType This type is publicly exposed as PrioritiesType. |
Definition at line 47 of file lang/plugins.hpp.
#include <plugins.hpp>
Public Type Index: | |
using | PluginType = TPlugin |
This exposes the template parameter TPlugin to the outer world. | |
using | PrioritiesType = TPriorities |
This exposes the template parameter pTPlugin to the outer world. | |
Public Method Index: | |
PrioritiesType | GetPriority () const |
Protected Field Index: | |
PrioritiesType | priority |
The priority of this plug-in. | |
Protected Method Index: | |
Plugin (PrioritiesType pPriority) | |
using PluginType = TPlugin |
This exposes the template parameter TPlugin to the outer world.
Definition at line 51 of file lang/plugins.hpp.
using PrioritiesType = TPriorities |
This exposes the template parameter pTPlugin to the outer world.
Definition at line 54 of file lang/plugins.hpp.
|
protected |
The priority of this plug-in.
Definition at line 58 of file lang/plugins.hpp.
|
inlineprotected |
Constructor which is protected, as this is a bace class.
pPriority | The priority that this plug-in uses. |
Definition at line 62 of file lang/plugins.hpp.
|
inline |
Returns the priority of this plug-in which is set during construction.
Definition at line 68 of file lang/plugins.hpp.