pion  5.0.6
Public Member Functions | Protected Types | List of all members
pion::plugin_ptr< InterfaceClassType > Class Template Reference

#include <plugin.hpp>

Inherits pion::plugin.

Public Member Functions

 plugin_ptr (void)
 default constructor & destructor
 
 plugin_ptr (const plugin_ptr &p)
 copy constructor
 
plugin_ptroperator= (const plugin_ptr &p)
 assignment operator
 
InterfaceClassType * create (void)
 creates a new instance of the plug-in object
 
void destroy (InterfaceClassType *object_ptr)
 destroys an instance of the plug-in object
 
- Public Member Functions inherited from pion::plugin
bool is_open (void) const
 returns true if a shared library is loaded/open
 
std::string get_plugin_name (void) const
 returns the name of the plugin that is currently open
 
void open (const std::string &plugin_name)
 
void open_file (const std::string &plugin_file)
 
void close (void)
 closes plug-in library
 

Protected Types

typedef InterfaceClassType * CreateObjectFunction(void)
 data type for a function that is used to create object instances
 
typedef void DestroyObjectFunction(InterfaceClassType *)
 data type for a function that is used to destroy object instances
 

Additional Inherited Members

- Static Public Member Functions inherited from pion::plugin
static bool find_plugin_file (std::string &path_to_file, const std::string &name)
 
static bool find_config_file (std::string &path_to_file, const std::string &name)
 
static void add_static_entry_point (const std::string &plugin_name, void *create_func, void *destroy_func)
 
static void check_cygwin_path (boost::filesystem::path &final_path, const std::string &path_string)
 
static void add_plugin_directory (const std::string &dir)
 appends a directory to the plug-in search path
 
static void reset_plugin_directories (void)
 clears all directories from the plug-in search path
 
static void get_all_plugin_names (std::vector< std::string > &plugin_names)
 returns a list of all Plugins found in all Plugin directories
 
- Protected Member Functions inherited from pion::plugin
 plugin (void)
 default constructor is private (use plugin_ptr class to create objects)
 
 plugin (const plugin &p)
 copy constructor
 
pluginoperator= (const plugin &p)
 assignment operator
 
void * get_create_function (void)
 returns a pointer to the plug-in's "create object" function
 
void * get_destroy_function (void)
 returns a pointer to the plug-in's "destroy object" function
 
void release_data (void)
 releases the plug-in's shared library symbols
 
void grab_data (const plugin &p)
 grabs a reference to another plug-in's shared library symbols
 

Detailed Description

template<typename InterfaceClassType>
class pion::plugin_ptr< InterfaceClassType >

plugin_ptr: smart pointer that manages plug-in code loaded from shared object libraries

Definition at line 301 of file plugin.hpp.


The documentation for this class was generated from the following file: