Logo Search packages:      
Sourcecode: libpodofo version File versions  Download package

const char * PoDoFo::PdfError::ErrorName ( EPdfError  eCode ) [static]

Get the name for a certain error code.

Returns:
the name or NULL if no name for the specified error code is available.

< 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.

Definition at line 177 of file PdfError.cpp.

References PoDoFo::ePdfError_ActionAlreadyPresent, PoDoFo::ePdfError_CannotConvertColor, PoDoFo::ePdfError_ChangeOnImmutable, PoDoFo::ePdfError_Date, PoDoFo::ePdfError_DestinationAlreadyPresent, PoDoFo::ePdfError_ErrOk, PoDoFo::ePdfError_FileNotFound, PoDoFo::ePdfError_Flate, PoDoFo::ePdfError_FreeType, PoDoFo::ePdfError_InternalLogic, PoDoFo::ePdfError_InvalidContentStream, PoDoFo::ePdfError_InvalidDataType, PoDoFo::ePdfError_InvalidDeviceOperation, PoDoFo::ePdfError_InvalidEncryptionDict, PoDoFo::ePdfError_InvalidEnumValue, PoDoFo::ePdfError_InvalidFontFile, PoDoFo::ePdfError_InvalidHandle, PoDoFo::ePdfError_InvalidHexString, PoDoFo::ePdfError_InvalidKey, PoDoFo::ePdfError_InvalidLinearization, PoDoFo::ePdfError_InvalidName, PoDoFo::ePdfError_InvalidPassword, PoDoFo::ePdfError_InvalidPredictor, PoDoFo::ePdfError_InvalidStream, PoDoFo::ePdfError_InvalidStreamLength, PoDoFo::ePdfError_InvalidStrokeStyle, PoDoFo::ePdfError_InvalidTrailerSize, PoDoFo::ePdfError_InvalidXRef, PoDoFo::ePdfError_InvalidXRefStream, PoDoFo::ePdfError_InvalidXRefType, PoDoFo::ePdfError_MissingEndStream, PoDoFo::ePdfError_MutexError, PoDoFo::ePdfError_NoNumber, PoDoFo::ePdfError_NoObject, PoDoFo::ePdfError_NoPdfFile, PoDoFo::ePdfError_NotImplemented, PoDoFo::ePdfError_NoTrailer, PoDoFo::ePdfError_NoXRef, PoDoFo::ePdfError_OutOfMemory, PoDoFo::ePdfError_PageNotFound, PoDoFo::ePdfError_SignatureError, PoDoFo::ePdfError_TestFailed, PoDoFo::ePdfError_UnexpectedEOF, PoDoFo::ePdfError_Unknown, PoDoFo::ePdfError_UnsupportedFilter, PoDoFo::ePdfError_UnsupportedFontFormat, PoDoFo::ePdfError_UnsupportedImageFormat, PoDoFo::ePdfError_ValueOutOfRange, and PoDoFo::ePdfError_WrongDestinationType.

Referenced by PrintErrorMsg(), and what().

{
    const char* pszMsg = NULL;

    switch( eCode ) 
    {
        case ePdfError_ErrOk:
            pszMsg = "ePdfError_ErrOk"; 
            break;
        case ePdfError_TestFailed:
            pszMsg = "ePdfError_TestFailed"; 
            break;
        case ePdfError_InvalidHandle:
            pszMsg = "ePdfError_InvalidHandle"; 
            break;
        case ePdfError_FileNotFound:
            pszMsg = "ePdfError_FileNotFound"; 
            break;
        case ePdfError_InvalidDeviceOperation:
            pszMsg = "ePdfError_InvalidDeviceOperation";
            break;
        case ePdfError_UnexpectedEOF:
            pszMsg = "ePdfError_UnexpectedEOF"; 
            break;
        case ePdfError_OutOfMemory:
            pszMsg = "ePdfError_OutOfMemory"; 
            break;
        case ePdfError_ValueOutOfRange:
            pszMsg = "ePdfError_ValueOutOfRange"; 
            break;
        case ePdfError_InternalLogic:
            pszMsg = "ePdfError_InternalLogic";
            break;
        case ePdfError_InvalidEnumValue:
            pszMsg = "ePdfError_InvalidEnumValue";
            break;
        case ePdfError_PageNotFound:
            pszMsg = "ePdfError_PageNotFound";
            break;
        case ePdfError_NoPdfFile:
            pszMsg = "ePdfError_NoPdfFile"; 
            break;
        case ePdfError_NoXRef:
            pszMsg = "ePdfError_NoXRef"; 
            break;
        case ePdfError_NoTrailer:
            pszMsg = "ePdfError_NoTrailer"; 
            break;
        case ePdfError_NoNumber:
            pszMsg = "ePdfError_NoNumber"; 
            break;
        case ePdfError_NoObject:
            pszMsg = "ePdfError_NoObject"; 
            break;
        case ePdfError_InvalidTrailerSize:
            pszMsg = "ePdfError_InvalidTrailerSize"; 
            break;
        case ePdfError_InvalidLinearization:
            pszMsg = "ePdfError_InvalidLinearization"; 
            break;
        case ePdfError_InvalidDataType:
            pszMsg = "ePdfError_InvalidDataType"; 
            break;
        case ePdfError_InvalidXRef:
            pszMsg = "ePdfError_InvalidXRef"; 
            break;
        case ePdfError_InvalidXRefStream:
            pszMsg = "ePdfError_InvalidXRefStream"; 
            break;
        case ePdfError_InvalidXRefType:
            pszMsg = "ePdfError_InvalidXRefType"; 
            break;
        case ePdfError_InvalidPredictor:
            pszMsg = "ePdfError_InvalidPredictor"; 
            break;
        case ePdfError_InvalidStrokeStyle:
            pszMsg = "ePdfError_InvalidStrokeStyle"; 
            break;
        case ePdfError_InvalidHexString:
            pszMsg = "ePdfError_InvalidHexString"; 
            break;
        case ePdfError_InvalidStream:
            pszMsg = "ePdfError_InvalidStream"; 
            break;
        case ePdfError_InvalidStreamLength:
            pszMsg = "ePdfError_InvalidStream"; 
            break;
        case ePdfError_InvalidKey:
            pszMsg = "ePdfError_InvalidKey";
            break;
        case ePdfError_InvalidName:
            pszMsg = "ePdfError_InvalidName";
            break;
        case ePdfError_InvalidEncryptionDict:
            pszMsg = "ePdfError_InvalidEncryptionDict";    /**< The encryption dictionary is invalid or misses a required key */
            break;
        case ePdfError_InvalidPassword:                    /**< The password used to open the PDF file was invalid */
            pszMsg = "ePdfError_InvalidPassword";
            break;
        case ePdfError_InvalidFontFile:
            pszMsg = "ePdfError_InvalidFontFile";
            break;
        case ePdfError_InvalidContentStream:
            pszMsg = "ePdfError_InvalidContentStream";
            break;
        case ePdfError_UnsupportedFilter:
            pszMsg = "ePdfError_UnsupportedFilter"; 
            break;
        case ePdfError_UnsupportedFontFormat:    /**< This font format is not supported by PoDoFO. */
            pszMsg = "ePdfError_UnsupportedFontFormat";
            break;
        case ePdfError_ActionAlreadyPresent:
            pszMsg = "ePdfError_ActionAlreadyPresent"; 
            break;
        case ePdfError_WrongDestinationType:
            pszMsg = "ePdfError_WrongDestinationType";
            break;
        case ePdfError_MissingEndStream:
            pszMsg = "ePdfError_MissingEndStream"; 
            break;
        case ePdfError_Date:
            pszMsg = "ePdfError_Date"; 
            break;
        case ePdfError_Flate:
            pszMsg = "ePdfError_Flate"; 
            break;
        case ePdfError_FreeType:
            pszMsg = "ePdfError_FreeType"; 
            break;
        case ePdfError_SignatureError:
            pszMsg = "ePdfError_SignatureError";
            break;
        case ePdfError_MutexError:
            pszMsg = "ePdfError_MutexError";
            break;
        case ePdfError_UnsupportedImageFormat:    /**< This image format is not supported by PoDoFO. */
            pszMsg = "ePdfError_UnsupportedImageFormat";
            break;
        case ePdfError_CannotConvertColor:       /**< This color format cannot be converted. */
            pszMsg = "ePdfError_CannotConvertColor";
            break;
        case ePdfError_NotImplemented:
            pszMsg = "ePdfError_NotImplemented";
            break;
        case ePdfError_DestinationAlreadyPresent:
            pszMsg = "ePdfError_DestinationAlreadyPresent"; 
            break;
        case ePdfError_ChangeOnImmutable:
            pszMsg = "ePdfError_ChangeOnImmutable";
            break;
        case ePdfError_Unknown:
            pszMsg = "ePdfError_Unknown"; 
            break;
        default:
            break;
    }

    return pszMsg;
}

Here is the caller graph for this function:


Generated by  Doxygen 1.6.0   Back to index