Hi,

  I am learning about <boost/dll/shared_library.hpp>

  So far I have manage to follow along with the tutorial I believe
https://www.boost.org/doc/libs/1_77_0/doc/html/boost_dll/tutorial.html

  Using tutorial 5 as an illustration


https://github.com/apolukhin/Boost.DLL/blob/develop/example/tutorial5/load_all.cpp

  On this line, I will have the ability to reference the object of
my_api_sum I believe


https://github.com/apolukhin/Boost.DLL/blob/develop/example/tutorial5/load_all.cpp#L99

  I have the following questions:

   1. If I have a class that is e.g. a shape, say rectangle (of different
   sizes), what approach may I use to create different instances of the class
   from the plugin?
   2. If my class requires parameters for it's construction, how do I pass
   it via the shared library loading mechanism ?


  Or have I been looking to use boost dll shared_library wrongly and that I
might look at the plugin being some sort of factory design approach ?

  Thank you in advance.

Cheers

-- 
Nicholas Yue
https://www.linkedin.com/in/nicholasyue/
_______________________________________________
Boost-users mailing list
Boost-users@lists.boost.org
https://lists.boost.org/mailman/listinfo.cgi/boost-users

Reply via email to