#include <PdfError.h>
Public Member Functions | |
| PdfError () | |
| PdfError (const EPdfError &eCode, const char *pszFile=NULL, int line=0, const char *pszInformation=NULL) | |
| PdfError (const PdfError &rhs) | |
| const PdfError & | operator= (const PdfError &rhs) |
| const PdfError & | operator= (const EPdfError &eCode) |
| bool | operator== (const PdfError &rhs) |
| bool | operator== (const EPdfError &eCode) |
| bool | operator!= (const PdfError &rhs) |
| bool | operator!= (const EPdfError &eCode) |
| EPdfError | GetError () const |
| const TDequeErrorInfo & | GetCallstack () const |
| void | SetError (const EPdfError &eCode, const char *pszFile=NULL, int line=0, const char *pszInformation=NULL) |
| void | SetErrorInformation (const char *pszInformation) |
| void | SetErrorInformation (const wchar_t *pszInformation) |
| void | AddToCallstack (const char *pszFile=NULL, int line=0, const char *pszInformation=NULL) |
| bool | IsError () const |
| void | PrintErrorMsg () const |
| virtual const char * | what () const throw () |
Static Public Member Functions | |
| static LogMessageCallback * | SetLogMessageCallback (LogMessageCallback *fLogMessageCallback) |
| static PODOFO_NOTHROW const char * | ErrorName (EPdfError eCode) |
| static const char * | ErrorMessage (EPdfError eCode) |
| static void | LogMessage (ELogSeverity eLogSeverity, const char *pszMsg,...) |
| static void | LogMessage (ELogSeverity eLogSeverity, const wchar_t *pszMsg,...) |
| static void | EnableLogging (bool bEnable) |
| static bool | LoggingEnabled () |
| static void | DebugMessage (const char *pszMsg,...) |
| static void | EnableDebug (bool bEnable) |
| static bool | DebugEnabled () |
A PdfError with Error() == ErrOk means successfull execution.
This class provides also meaningfull error descriptions.
| PoDoFo::PdfError::PdfError | ( | ) |
Create a PdfError object initialized to ErrOk
| PoDoFo::PdfError::PdfError | ( | const EPdfError & | eCode, | |
| const char * | pszFile = NULL, |
|||
| int | line = 0, |
|||
| const char * | pszInformation = NULL | |||
| ) |
Create a PdfError object with a given error code.
| eCode | the error code of this object | |
| pszFile | the file in which the error has occured. Use the compiler macro __FILE__ to initialize the field. | |
| line | the line in which the error has occured. Use the compiler macro __LINE__ to initialize the field. | |
| pszInformation | additional information on this error which mayy be formatted like printf |
| PoDoFo::PdfError::PdfError | ( | const PdfError & | rhs | ) |
Copy constructor
| rhs | copy the contents of rhs into this object |
| void PoDoFo::PdfError::AddToCallstack | ( | const char * | pszFile = NULL, |
|
| int | line = 0, |
|||
| const char * | pszInformation = NULL | |||
| ) | [inline] |
Add callstack information to an error object. Always call this function if you get an error object but do not handle the error but throw it again.
| pszFile | the filename of the source file causing the error or NULL. Typically you will use the gcc macro __FILE__ here. | |
| line | the line of source causing the error or 0. Typically you will use the gcc macro __LINE__ here. | |
| pszInformation | additional information on the error. e.g. how to fix the error. This string is intended to be shown to the user. |
| static bool PoDoFo::PdfError::DebugEnabled | ( | ) | [inline, static] |
Is the display of debugging messages enabled or not?
| void PoDoFo::PdfError::DebugMessage | ( | const char * | pszMsg, | |
| ... | ||||
| ) | [static] |
Log a message to the logging system defined for PoDoFo for debugging
| pszMsg | the message to be logged |
| static void PoDoFo::PdfError::EnableDebug | ( | bool | bEnable | ) | [inline, static] |
Enable or disable the display of debugging messages
| bEnable | enable (true) or disable (false) |
| static void PoDoFo::PdfError::EnableLogging | ( | bool | bEnable | ) | [inline, static] |
Enable or disable Logging
| bEnable | enable (true) or disable (false) |
| const char * PoDoFo::PdfError::ErrorMessage | ( | EPdfError | eCode | ) | [static] |
Get the error message for a certain error code.
| const char * PoDoFo::PdfError::ErrorName | ( | EPdfError | eCode | ) | [static] |
Get the name for a certain error code.
< The encryption dictionary is invalid or misses a required key
< The password used to open the PDF file was invalid
< This font format is not supported by PoDoFO.
< This image format is not supported by PoDoFO.
< This color format cannot be converted.
| const TDequeErrorInfo & PoDoFo::PdfError::GetCallstack | ( | ) | const [inline] |
Get access to the internal callstack of this error
| EPdfError PoDoFo::PdfError::GetError | ( | ) | const [inline] |
Return the error code of this object
| bool PoDoFo::PdfError::IsError | ( | ) | const [inline] |
| static bool PoDoFo::PdfError::LoggingEnabled | ( | ) | [inline, static] |
Is the display of debugging messages enabled or not?
| void PoDoFo::PdfError::LogMessage | ( | ELogSeverity | eLogSeverity, | |
| const wchar_t * | pszMsg, | |||
| ... | ||||
| ) | [static] |
Log a message to the logging system defined for PoDoFo.
| eLogSeverity | the sevirity of the log message | |
| pszMsg | the message to be logged |
| void PoDoFo::PdfError::LogMessage | ( | ELogSeverity | eLogSeverity, | |
| const char * | pszMsg, | |||
| ... | ||||
| ) | [static] |
Log a message to the logging system defined for PoDoFo.
| eLogSeverity | the sevirity of the log message | |
| pszMsg | the message to be logged |
| bool PoDoFo::PdfError::operator!= | ( | const EPdfError & | eCode | ) |
Overloaded comparison operator compares 2 PdfError objects
| eCode | an erroce code |
| bool PoDoFo::PdfError::operator!= | ( | const PdfError & | rhs | ) |
Overloaded assignment operator
| eCode | a EPdfError code |
| bool PoDoFo::PdfError::operator== | ( | const EPdfError & | eCode | ) |
Overloaded comparison operator compares 2 PdfError objects
| eCode | an erroce code |
| bool PoDoFo::PdfError::operator== | ( | const PdfError & | rhs | ) |
| void PoDoFo::PdfError::PrintErrorMsg | ( | ) | const |
Print an error message to stderr
| void PoDoFo::PdfError::SetError | ( | const EPdfError & | eCode, | |
| const char * | pszFile = NULL, |
|||
| int | line = 0, |
|||
| const char * | pszInformation = NULL | |||
| ) | [inline] |
Set the error code of this object.
| eCode | the error code of this object | |
| pszFile | the filename of the source file causing the error or NULL. Typically you will use the gcc macro __FILE__ here. | |
| line | the line of source causing the error or 0. Typically you will use the gcc macro __LINE__ here. | |
| pszInformation | additional information on the error. e.g. how to fix the error. This string is intended to be shown to the user. |
| void PoDoFo::PdfError::SetErrorInformation | ( | const wchar_t * | pszInformation | ) | [inline] |
Set additional error informatiom
| pszInformation | additional information on the error. e.g. how to fix the error. This string is intended to be shown to the user. |
| void PoDoFo::PdfError::SetErrorInformation | ( | const char * | pszInformation | ) | [inline] |
Set additional error informatiom
| pszInformation | additional information on the error. e.g. how to fix the error. This string is intended to be shown to the user. |
| PdfError::LogMessageCallback * PoDoFo::PdfError::SetLogMessageCallback | ( | LogMessageCallback * | fLogMessageCallback | ) | [static] |
Set a global static LogMessageCallback functor to repleace stderr output in LogMessageInternal
| fLogMessageCallback | the pointer to the new callback functor object |
| const char * PoDoFo::PdfError::what | ( | ) | const throw () [virtual] |
Reimplemented from std::exception.
1.4.7