te::plugin::CppPluginEngine Class Reference

An abstract class for plugin engines. More...

#include <CppPluginEngine.h>

Inheritance diagram for te::plugin::CppPluginEngine:
te::plugin::AbstractPluginEngine

Public Member Functions

 CppPluginEngine ()
 
AbstractPluginload (const PluginInfo &pInfo)
 It try to create and load the informed plugin. More...
 
void unload (AbstractPlugin *plugin)
 It try to unload the informed plugin. More...
 
 ~CppPluginEngine ()
 Destructor. More...
 

Static Public Member Functions

static std::string getPluginFileName (const std::string &libName)
 This method will help to form the library name wich contains the plugin. More...
 

Detailed Description

An abstract class for plugin engines.

A plugin engine for plugins written in C++.

For each kind of programming language there will be an specific engine capable of loading and preparing the plugin before the startup method is called.

,

See also
Plugin, PluginInfo, PluginEngineFactory, CppPluginEngine
Plugin, PluginInfo, PluginEngineFactory, PluginEngine

Definition at line 50 of file CppPluginEngine.h.

Constructor & Destructor Documentation

te::plugin::CppPluginEngine::CppPluginEngine ( )

Default construtor.

te::plugin::CppPluginEngine::~CppPluginEngine ( )
inline

Destructor.

Definition at line 58 of file CppPluginEngine.h.

Member Function Documentation

static std::string te::plugin::CppPluginEngine::getPluginFileName ( const std::string &  libName)
static

This method will help to form the library name wich contains the plugin.

This method may append a prefix and suffix that are platform dependent and also the build mode: DEBUG or RELEASE.

AbstractPlugin* te::plugin::CppPluginEngine::load ( const PluginInfo pInfo)
virtual

It try to create and load the informed plugin.

Parameters
pInfoThe information needed to create and load the plugin.
Returns
It returns a loaded plugin. The caller will take the ownership of the returned plugin.
Exceptions
ExceptionIt throws an exception if the plugin can not be loaded.
Note
If the parameter PluginInfo::m_folder does not contains the required plugin it may be searched and loaded using a set of default paths.

Implements te::plugin::AbstractPluginEngine.

void te::plugin::CppPluginEngine::unload ( AbstractPlugin plugin)
virtual

It try to unload the informed plugin.

On success the informed plugin will be also destroyed and its pointer will be invalidated.

Parameters
pluginThe plugin to be unloaded.
Exceptions
ExceptionIt throws an exception if the plugin can not be unloaded.

Implements te::plugin::AbstractPluginEngine.


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