charon-core  0.3.1
AbstractPluginLoader::PluginException Class Reference

Plugin Exception class. More...

#include <charon-core/AbstractPluginLoader.h>

Inheritance diagram for AbstractPluginLoader::PluginException:

Public Types

enum  ErrorCode {
  FILE_NOT_FOUND = 1, FILE_DAMAGED = 2, INVALID_PLUGIN_FORMAT = 3, ALREADY_LOADED = 4,
  PLUGIN_NOT_LOADED = 5, NO_SUCH_INSTANCE = 6, DUPLICATE_INSTANCE_NAME = 7, INCOMPATIBLE_BUILD_TYPE = 8,
  VERSION_INFORMATION_MISSING = 9, VERSION_MISSMATCH = 10, OTHER = 0
}
 Error Reason Enum. More...
 

Public Member Functions

 PluginException (const std::string &message, const std::string &pluginName="", ErrorCode err=OTHER)
 Constructor. More...
 
virtual ~PluginException () throw ()
 Destructor.
 
ErrorCode getErrorCode () const
 Plugin Exception Error Code. More...
 
const std::string & getPluginName () const
 Get Plugin Name. More...
 

Private Attributes

ErrorCode _err
 Saves the reason of the error.
 
std::string _nameOfPlugin
 Name of the plugin causing the error.
 

Detailed Description

Provides information about the reason of the error

Definition at line 67 of file AbstractPluginLoader.h.

Member Enumeration Documentation

Enumerator
FILE_NOT_FOUND 

Plugin file doesn't exist or is placed in the wrong directory.

FILE_DAMAGED 

File is damaged, unreadable, not a shared object or the user access rights are insufficient.

INVALID_PLUGIN_FORMAT 

File is a shared object but misses required functions.

ALREADY_LOADED 

A plugin with the same name is already loaded.

PLUGIN_NOT_LOADED 

While unloading a plugin or deleting an instance: The plugin is not loaded.

NO_SUCH_INSTANCE 

Requested instance doesn't exist.

DUPLICATE_INSTANCE_NAME 

An instance with the same name already exists.

INCOMPATIBLE_BUILD_TYPE 

Plugin was linked against incompatible runtime library.

VERSION_INFORMATION_MISSING 

Version information for the plugin is missing while explicit version check was requested.

VERSION_MISSMATCH 

there is a missmatch between the current charon-core version and the version the plugin was compiled with

OTHER 

Other reason.

Definition at line 70 of file AbstractPluginLoader.h.

Constructor & Destructor Documentation

AbstractPluginLoader::PluginException::PluginException ( const std::string &  message,
const std::string &  pluginName = "",
ErrorCode  err = OTHER 
)
Parameters
messageException message
pluginNameName of the plugin causing the exception
errReason of the exception

Definition at line 67 of file AbstractPluginLoader.cpp.

Member Function Documentation

AbstractPluginLoader::PluginException::ErrorCode AbstractPluginLoader::PluginException::getErrorCode ( ) const
Returns
Reason of the exception

Definition at line 77 of file AbstractPluginLoader.cpp.

const std::string & AbstractPluginLoader::PluginException::getPluginName ( ) const
Returns
Name of the plugin causing the exception

Definition at line 72 of file AbstractPluginLoader.cpp.


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