Tellurium Plugin C++ API  1.0.0
 All Classes Files Functions Variables Friends Pages
Public Member Functions | Protected Attributes | List of all members
tlp::CPlugin Class Reference

#include <telCPlugin.h>

Inheritance diagram for tlp::CPlugin:
tlp::Plugin

Public Member Functions

 CPlugin (const string &name, const string &cat=gNoneString, RoadRunner *aRR=NULL)
 Create a plugin written in C.
 
virtual ~CPlugin ()
 De allocate the plugin.
 
string getImplementationLanguage ()
 
virtual bool execute (bool useThread=false)
 
tlp::StringList getPropertyNames ()
 
PropertyBase * getProperty (const string &param)
 
string getLastError ()
 Function to retrieve last error in a C plugin.
 
- Public Member Functions inherited from tlp::Plugin
 Plugin (const string &name=gEmptyString, const string &cat=gNoneString, RoadRunner *aRR=NULL, const string &language=gNoneString, const PluginManager *pm=NULL)
 
virtual ~Plugin ()
 
string getName ()
 
string getLibraryName ()
 
string getAuthor ()
 
string getCategory ()
 
string getDescription ()
 
string getHint ()
 
string getVersion ()
 
string getCopyright ()
 
RoadRunner * getRoadRunnerInstance ()
 
virtual string getInfo ()
 
virtual string getExtendedInfo ()
 
virtual unsigned char * getManualAsPDF () const
 
virtual unsigned int getPDFManualByteSize ()
 
virtual Properties * getProperties ()
 
string getPluginPropertiesAsXML ()
 
string getPropertyValueAsString (const string &param)
 
void * getPropertyValueHandle (const string &param)
 
void setPropertyByString (const string &nameOf, const char *value)
 
void setPropertyValue (const string &nameOf, const void *value)
 
void terminate ()
 
bool isBeingTerminated () const
 
bool wasTerminated () const
 check if the plugin was terminated
 
virtual bool isWorking () const
 check if the plugin is working
 
virtual bool assignRoadRunnerInstance (RoadRunner *rr)
 Assign a roadrunner instance for the plugin to use.
 
virtual bool assignOnStartedEvent (PluginEvent pluginStarted, void *userData1=NULL, void *userData2=NULL)
 
virtual bool assignOnProgressEvent (PluginEvent pluginsProgress, void *userData1=NULL, void *userData2=NULL)
 
virtual bool assignOnFinishedEvent (PluginEvent pluginsFinished, void *userData1=NULL, void *userData2=NULL)
 
virtual string getResult ()
 
virtual bool resetPlugin ()
 
virtual string getStatus ()
 
bool hasStartedEvent () const
 
bool hasProgressEvent () const
 
bool hasFinishedEvent () const
 
void WorkStartedEvent (void *data1, void *data2)
 
void WorkProgressEvent (void *data1, void *data2)
 
void WorkFinishedEvent (void *data1, void *data2)
 
pair< void *, void * > getWorkStartedData ()
 
pair< void *, void * > getWorkProgressData ()
 
pair< void *, void * > getWorkFinishedData ()
 
const PluginManagergetPluginManager ()
 

Protected Attributes

executeF executeFunction
 
destroyF destroyFunction
 
getACharStarF getCPropertyNames
 
getAPropertyF getCProperty
 
getACharStarF getCLastError
 
- Protected Attributes inherited from tlp::Plugin
string mName
 Name of Plugin.
 
string mLibraryName
 Name of compiled shared library implementing the Plugin.
 
string mAuthor
 Name of plugin author(s)
 
string mCategory
 Plugin category.
 
string mDescription
 Plugin description.
 
string mHint
 Plugin Hint.
 
string mVersion
 Plugin version.
 
string mCopyright
 Plugin copyright language.
 
string mImplementationLanguage
 Plugin implementation language.
 
bool mTerminate
 Boolean flag indicating if a user wants to terminate the work in a plugin.
 
bool mIsWorking
 Boolean flag indicating if the plugin is working.
 
RoadRunner * mRR
 
const PluginManagermPM
 
PluginEvent mWorkStartedEvent
 
PluginEvent mWorkProgressEvent
 
PluginEvent mWorkFinishedEvent
 
void * mWorkStartedData1
 
void * mWorkStartedData2
 
void * mWorkProgressData1
 
void * mWorkProgressData2
 
void * mWorkFinishedData1
 
void * mWorkFinishedData2
 
Properties mProperties
 

Additional Inherited Members

- Protected Member Functions inherited from tlp::Plugin
void setLibraryName (const string &libName)
 

Detailed Description

The CPlugin class is containing the framework to load plugins that are written in pure C. The shared library need to export an execute and destroy function.

Member Function Documentation

bool tlp::CPlugin::execute ( bool  inAThread = false)
virtual

Execute the plugin

Implements tlp::Plugin.

string tlp::CPlugin::getImplementationLanguage ( )
virtual

Retrieve the implementation language of the plugin.

Implements tlp::Plugin.

PropertyBase * tlp::CPlugin::getProperty ( const string &  param)
virtual

Retieves a specific property

Reimplemented from tlp::Plugin.

tlp::StringList tlp::CPlugin::getPropertyNames ( )
virtual

Retieves the names of the propertys

Reimplemented from tlp::Plugin.

Member Data Documentation

destroyF tlp::CPlugin::destroyFunction
protected

Function pointer to a destroy function. The shared library need to provide this function. This function pointer is assigned as the plugin is loaded.

executeF tlp::CPlugin::executeFunction
protected

Function pointer to a execute function. The shared library need to provide this function. This function pointer is assigned as the plugin is loaded.

getACharStarF tlp::CPlugin::getCPropertyNames
protected

Function pointer to retrieve the C plugins list of properties.


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