How to pass a pointer to a C++ plugin -


in our company we're using plugin system i've written using qt plugin system. each plugin has "needed functions" , "own functions" so, if plugin needs function called *func_1*, there must plugin has function called *func_1*.

this works great, have problem: plugin needs know pointer class object plugin uses external. cannot put kind of information class in plugins interface has nothing it.

the solution have, write interface function can pass void pointers, i'd know if there's other solutions maybe less c style.

thanks in advance.

the modern c++ "replacement" void-pointer boost.any. it'll allow pass through interface, , still gives type-safety.


Comments

Popular posts from this blog

Add email recipient to all new Trac tickets -

400 Bad Request on Apache/PHP AddHandler wrapper -

php - Change action and image src url's with jQuery -