
#ifndef _BP_EXCEPTION_
#define _BP_EXCEPTION_

#include "stl_exception.h"

/*------------------------------------------------------------------------------
*
*  Pattern for new exception class
*
*  copy example code and replace all $$NEW_CLASS$$ identifiers with the name of 
*  the new exception class and all $$BASE_CLASS$$ identifiers with the name of
*  the base exception class (e.g. exception)
*

class $$NEW_CLASS$$ : public $$BASE_CLASS$$
{
public:
    $$NEW_CLASS$$(tU32 u32Error = 0)
       : $$BASE_CLASS$$("$$NEW_CLASS$$", u32Error)
    {
       oOwnType.pParent = &$$BASE_CLASS$$::oThisType;
       ERR_M_ASSERT(sizeof(*this) == sizeof(exception));
    }
    $$NEW_CLASS$$(const tChar* coszDescription, tU32 u32Error = 0)
       : $$BASE_CLASS$$(coszDescription, u32Error)
    {
       oThisType.pParent = &$$BASE_CLASS$$::oThisType;
       ERR_M_ASSERT(sizeof(*this) == sizeof(exception));
    }

    static tclTypeInfo* poGetClassTypeInfo()
    {
       return &oThisType;
    }

protected:
    virtual tclTypeInfo* poGetTypeInfo()
    {
       return &oThisType;
    }

    static tclTypeInfo oThisType;
};

bpstl::exception::tclTypeInfo bpstl::$$NEW_CLASS$$::oThisType; // implement in cpp file
-------------------------------------------------------------------------------*/


#endif /* _BP_EXCEPTION_ */


