Image Component Library (ICL)
|
Utility class for plugin registration. More...
#include <PluginRegister.h>
Classes | |
struct | Plugin |
internally used instance type: More... | |
Public Types | |
typedef std::map< std::string, std::string > | Data |
data used for instance creation More... | |
typedef utils::Function< T *, const Data & > | CreateFunction |
creator function for instances More... | |
Public Member Functions | |
void | add (const std::string &name, CreateFunction create, const std::string &description, const std::string &creationSyntax) |
adds a new plugin More... | |
T * | createInstance (const std::string &name, const Data &data) |
creates an instance (or throws More... | |
std::string | getRegisteredInstanceDescription () |
returns a string representation of all registered types More... | |
const std::map< std::string, Plugin > & | getRegisteredPlugins () const |
returns a all registered plugins More... | |
Static Public Member Functions | |
static PluginRegister< T > & | instance () |
returns the static instance for the specific type More... | |
Private Member Functions | |
PluginRegister () | |
private constructor (use singelton creator function instance()) More... | |
Private Attributes | |
std::map< std::string, Plugin > | plugins |
internal plugin list More... | |
Utility class for plugin registration.
typedef utils::Function<T*,const Data&> icl::utils::PluginRegister< T >::CreateFunction |
creator function for instances
typedef std::map<std::string,std::string> icl::utils::PluginRegister< T >::Data |
data used for instance creation
|
inlineprivate |
private constructor (use singelton creator function instance())
|
inline |
adds a new plugin
|
inline |
creates an instance (or throws
|
inline |
returns a string representation of all registered types
|
inline |
returns a all registered plugins
|
inlinestatic |
returns the static instance for the specific type
|
private |
internal plugin list