c++ - Boost Plugin choices -


i'm looking implement plugin architecture our current application (unix, c++) , have been reviewing options (pending approval) within boost libraries.

edit: i'm looking dynamically add classes @ runtime.

boost.plugin

boost.reflection

boost.extension

i wondering everyones experience/opinion on these , other implementations.

eh. used dlopen , dlsym along pair of extern "c" static functions must defined in dll

extern "c" static plugin* create( arg_pack* ); extern "c" static errno_t destroy( plugin* ); 

have plugin-manager ".dll" or ".so" files , load them a
map<string, pair< plugin*(*)(arg_pack*), errno_t(*)(plugin*)> >

you can lookup plugin based on name (the string above) , it's 'constructor' or 'destructor'

see also: gmodule


Comments

Popular posts from this blog

java - SNMP4J General Variable Binding Error -

windows - Python Service Installation - "Could not find PythonClass entry" -

Determine if a XmlNode is empty or null in C#? -