ParCompMark::DynLoad Class Reference

#include <PCMDynLoad.h>

Inheritance diagram for ParCompMark::DynLoad:

Inheritance graph
[legend]
List of all members.

Detailed Description

Dynamic load library.

Definition at line 50 of file PCMDynLoad.h.


Methods

virtual bool hasFunction (const std::string &funcName) const
 Return true when the dynamic library has a callable function with the specified name.
virtual void * getFunction (const std::string &funcName) const
 Get a function pointer from dynamic library by name (symbol).
virtual void load ()
 Load a library.
virtual void unload ()
 Load a library.

Public Types

typedef Pointer< DynLoad,
Mutex
Pointer
 Type for pointer on this class.

Public Member Functions

Constructors & destructor
 DynLoad (const std::string &libName)
 Create a Dynamic load class, and load the libName named library.
virtual ~DynLoad ()
 The destructor.
Getters & setters
void * getHandle () const
 Getter of mHandle.
const std::string & getLibraryName () const
 Getter of mLibraryName.

Protected Attributes

Variables
void * mHandle
 The dynamic library handler.
std::string mLibraryName
 The dynamic library name.

Member Typedef Documentation

Type for pointer on this class.

Reimplemented in ParCompMark::Plugin, and ParCompMark::RendererPlugin.

Definition at line 68 of file PCMDynLoad.h.


Constructor & Destructor Documentation

ParCompMark::DynLoad::DynLoad ( const std::string &  libName  ) 

Create a Dynamic load class, and load the libName named library.

Parameters:
[in] libName Name of the loaded library

Definition at line 44 of file PCMDynLoad.cpp.

References load(), and mLibraryName.

Here is the call graph for this function:

ParCompMark::DynLoad::~DynLoad (  )  [virtual]

The destructor.

This class has virtual destructor.

Definition at line 55 of file PCMDynLoad.cpp.

References mHandle, and unload().

Here is the call graph for this function:


Member Function Documentation

void * ParCompMark::DynLoad::getHandle (  )  const [inline]

Getter of mHandle.

Returns value of mHandle.

Returns:
The value of mHandle

Definition at line 216 of file PCMDynLoad.h.

const std::string & ParCompMark::DynLoad::getLibraryName (  )  const [inline]

Getter of mLibraryName.

Returns value of mLibraryName.

Returns:
The value of mLibraryName

Definition at line 223 of file PCMDynLoad.h.

bool ParCompMark::DynLoad::hasFunction ( const std::string &  funcName  )  const [virtual]

void ParCompMark::DynLoad::load (  )  [protected, virtual]

Load a library.

Called by constructor.

Definition at line 101 of file PCMDynLoad.cpp.

References Except, ParCompMark::Singleton< T >::getInstance(), mHandle, mLibraryName, and ParCompMark::Logger::NOTICE.

Referenced by DynLoad().

Here is the call graph for this function:

void ParCompMark::DynLoad::unload (  )  [protected, virtual]

Load a library.

Called by constructor.

Definition at line 113 of file PCMDynLoad.cpp.

References Except, ParCompMark::Singleton< T >::getInstance(), mHandle, mLibraryName, and ParCompMark::Logger::NOTICE.

Referenced by ~DynLoad().

Here is the call graph for this function:


Member Data Documentation

void* ParCompMark::DynLoad::mHandle [protected]

The dynamic library handler.

Remarks:
This is own attribute of this class.

Definition at line 84 of file PCMDynLoad.h.

Referenced by getFunction(), hasFunction(), load(), unload(), and ~DynLoad().

std::string ParCompMark::DynLoad::mLibraryName [protected]

The dynamic library name.

Remarks:
This is own attribute of this class.

Definition at line 91 of file PCMDynLoad.h.

Referenced by DynLoad(), load(), ParCompMark::Plugin::Plugin(), unload(), and ParCompMark::Plugin::~Plugin().


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