Class CErrorHandler Data ItemsConstructorsDestructorsFunctionsCustom CodeGo to hierarchy chart    Prev page: Custom Code in Header After Class DeclarationNext page: Custom Code in Source After Includes    Show member index
Custom Code in Header Public Section Declared in:
ErrorHandler.h

'Custom Code' icon -- Shortcut to top of page. Custom Code

//Log priority
typedef enum _LogPriority
{
    lpDebug,
    lpMessage,
    lpCritical,
    lpError
} LogPriority;

//The external log
class CErrorLog
{
    friend class CErrorHandler;
public:
    //Do we auto flush?
    //If so, will try to flush medium after each write
    void SetAutoFlush(BOOL bFlush);
    BOOL GetAutoFlush()const;

    //Assignment operator
    CErrorLog& operator=(const CErrorLog& rLog);

    //Ctor and Dtor
    CErrorLog();
    CErrorLog(const CErrorLog& rLog);
    virtual ~CErrorLog();
protected:
    //Report an error must overide
    virtual void ReportError(const std::string& rClass,
                             const std::string& rMethod,
                             const std::string& rMessage)=0;

    //Report a regular message
    virtual void WriteMessage(const std::string& rClass,
                              const std::string& rMethod,
                              const std::string& rMessage,
                              LogPriority aPriority)=0;
private:
    //Do we auto flush
    BOOL m_bAutoFlush;
};

'See Also' icon -- Shortcut to top of page. See Also

Class Overview Class Overview  |  Hierarchy Chart Hierarchy Chart


Get Surveyor!This web site was generated using Surveyor V4.50.811.1.  Click here for more information. Site content copyright © 2003 Komodia LTD.. See the About page for additional notices. This page last updated: 24 Feb 2003.