PKIFException.h

Go to the documentation of this file.
00001 
00010 #ifndef __PKIFEXCEPTION_H__
00011 #define __PKIFEXCEPTION_H__
00012 
00013 #include "PKIFdll.h"
00014 #include "components.h"
00015 #include <exception>
00016 #include <vector>
00017 
00018 #define MAX_EXCEPTION_STRING 255
00019 
00020 FD_SMART_PTR(ExceptionInfo);
00021 //#include "ExceptionInfo.h"
00022 
00023 struct CPKIFExceptionImpl;
00024 
00033 class CAC_API CPKIFException : public std::exception
00034 {
00035 public:
00036     //All exceptions must be constructed using a subcomponent ID and an errorCode (whether or not they
00037     //signify anything is your business).  Optionally, an errorDescription and/or fileName and line number
00038     //can be provided.  The fileName uses the pointer passed in so makes sure it's scope is sufficient.  The 
00039     //errorDescription is maintained as a copy.
00040     CPKIFException(const CPKIFException& e);
00041     CPKIFException(int subComponentID, int errorCode);
00042     CPKIFException(int subComponentID, int errorCode, char* fileName, int lineNumber);
00043     CPKIFException(int subComponentID, int errorCode, const char* errorDescription);                                     //DESCRIPTION MUST NOT BE NULL
00044     CPKIFException(int subComponentID, int errorCode, const char* errorDescription, char* fileName, int lineNumber); //DESCRIPTION MUST NOT BE NULL
00045     virtual ~CPKIFException(void) STDLIB_SUPER_THROW;
00046 
00047     void push_info(CPKIFException& e2);
00048     void GetExceptionInfos(std::vector<ExceptionInfoPtr>& v);
00049     
00050     int GetErrorCode() const; 
00051     int GetSubcomponentID() const; 
00052     const char* GetDescription() const;                               
00053 
00054     CPKIFStringPtr print() const;
00055 
00056 private:
00058     CPKIFException& operator=(const CPKIFException& rhs); //added 8/21/2004
00060     
00061     struct CPKIFExceptionImpl *m_impl;
00062 };
00063 
00064 #endif

Generated on Mon Nov 15 11:15:54 2010 for PublicKeyInfrastructureFramework(PKIF) by  doxygen 1.5.6