Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for a snapshot of the master branch, built from commit b3176dd2ba.
PrevUpHomeNext

Function template get

boost::dll::experimental::get

Synopsis

// In header: <boost/dll/smart_library.hpp>


template<typename Class, typename Signature> 
  auto get(const smart_library & sm, const std::string & name);

Description

Helper functions for overloads.

Gets either a variable, function or member-function, depending on the signature.

smart_library sm("lib.so");
get<int>(sm, "space::value"); //import a variable
get<void(int)>(sm, "space::func"); //import a function
get<some_class, void(int)>(sm, "space::class_::mem_fn"); //import a member function

Parameters:

sm

A reference to the smart_library

name

The name of the entity to import


PrevUpHomeNext