home *** CD-ROM | disk | FTP | other *** search
Text File | 1996-12-20 | 1.1 KB | 54 lines | [TEXT/CWIE] |
- ///////////////////////////////////////////////////////////////////////////////
- //
- // This file is a BDIAMOND addition.
- //
-
- #include "ocheaders.h"
- #include "FnAssert.h"
- #include "CError.h"
-
- ///////////////////////////////////////////////////////////////////////////////
- //
- // CError::CError
- //
-
- CError::CError(ErrorCode error)
- {
- this->Init(error);
- }
-
- CError::CError(ErrorCode error, CErrorControl * control)
- {
- this->Init(error, control);
- }
-
- ///////////////////////////////////////////////////////////////////////////////
- //
- // CError::Init
- //
- void CError::Init(ErrorCode error, CErrorControl * control)
- {
- // just a little init function that all the contructors call. Mostly
- // to make it easier to set a breakpoint in the debugger upon an error.
- mErrorCode = error;
- mControl = control;
- }
-
- ///////////////////////////////////////////////////////////////////////////////
- //
- // CError::HandleError
- //
-
- void CError::HandleError(void)
- {
- switch ( mErrorCode )
- {
- case FAILED_ASSERTION_ERROR:
- throw; // just cause a termination
- break;
-
- default:
- break;
- }
- }
-