GME  13
Defines
GMEOLEError.h File Reference

Go to the source code of this file.

Defines

#define ID_ERROR_FIRST   100
#define ID_ERROR_PROJECT_NOT_OPEN   (ID_ERROR_FIRST + 1)
#define ID_ERROR_MGAPROJECT_NOT_OPEN   (ID_ERROR_FIRST + 2)
#define ID_ERROR_PROJECT_OPEN   (ID_ERROR_FIRST + 3)
#define ID_ERROR_NO_CONSTMGR   (ID_ERROR_FIRST + 4)
#define ID_ERROR_MODEL_INVALID   (ID_ERROR_FIRST + 5)
#define ID_ERROR_ASPECT_INVALID   (ID_ERROR_FIRST + 6)
#define ID_ERROR_PANEL_INVALID   (ID_ERROR_FIRST + 7)
#define ID_ERROR_PTR_INVALID   (ID_ERROR_FIRST + 8)
#define ID_ERROR_NOT_FOUND   (ID_ERROR_FIRST + 9)
#define PRECONDITION_ACTIVE_PROJECT
#define PRECONDITION_ACTIVE_REAL_MGA_PROJECT
#define PRECONDITION_NO_PROJECT
#define PRECONDITION_ACTIVE_CONSTMGR
#define PRECONDITION_VALID_MODEL
#define PRECONDITION_VALID_ASPECT
#define PRECONDITION_VALID_PANEL
#define PRECONDITION_VALID_PTR(x, y)
#define SHOW_ERROR(z)
#define THROW_IF_NULL(x, y)
#define THROW_IF_BOOL(x, y)

Define Documentation

Definition at line 11 of file GMEOLEError.h.

#define ID_ERROR_FIRST   100

Definition at line 5 of file GMEOLEError.h.

Definition at line 7 of file GMEOLEError.h.

Definition at line 10 of file GMEOLEError.h.

Definition at line 9 of file GMEOLEError.h.

#define ID_ERROR_NOT_FOUND   (ID_ERROR_FIRST + 9)

Definition at line 14 of file GMEOLEError.h.

Definition at line 12 of file GMEOLEError.h.

Definition at line 6 of file GMEOLEError.h.

Definition at line 8 of file GMEOLEError.h.

Definition at line 13 of file GMEOLEError.h.

Value:
if (theApp.mgaConstMgr == NULL) { \
                AfxThrowOleDispatchException(ID_ERROR_NO_CONSTMGR, \
                        _T("GUI has no active Constraint Manager.")); \
        }

Definition at line 34 of file GMEOLEError.h.

Value:
if (theApp.guiMetaProject == NULL) { \
                AfxThrowOleDispatchException(ID_ERROR_PROJECT_NOT_OPEN, \
                        _T("GUI has no active MGA project.")); \
        }

Definition at line 16 of file GMEOLEError.h.

Value:
if ((theApp.mgaProject == NULL) || (!theApp.proj_type_is_mga)) { \
                AfxThrowOleDispatchException(ID_ERROR_MGAPROJECT_NOT_OPEN, \
                        _T("GUI has no active (valid) MGA project.")); \
        }

Definition at line 22 of file GMEOLEError.h.

Value:
if (theApp.guiMetaProject != NULL) { \
                AfxThrowOleDispatchException(ID_ERROR_PROJECT_OPEN, \
                        _T("GUI has active MGA project.")); \
        }

Definition at line 28 of file GMEOLEError.h.

Value:
if (!AmIValid()) { \
                AfxThrowOleDispatchException(ID_ERROR_ASPECT_INVALID, \
                        _T("Aspect is invalid. Probably its model window is closed.")); \
        }

Definition at line 46 of file GMEOLEError.h.

Value:
if (!AmIValid()) { \
                AfxThrowOleDispatchException(ID_ERROR_MODEL_INVALID, \
                        _T("Model window is invalid. Probably it is closed.")); \
        }

Definition at line 40 of file GMEOLEError.h.

Value:
if ((!m_control) || (!m_control->GetSafeHwnd())) { \
                AfxThrowOleDispatchException(ID_ERROR_PANEL_INVALID, \
                        _T("GUI panel is invalid.")); \
        }

Definition at line 52 of file GMEOLEError.h.

#define PRECONDITION_VALID_PTR (   x,
 
)
Value:
if ( (!x)) { \
                AfxThrowOleDispatchException(ID_ERROR_PTR_INVALID, \
                        _T(y)); \
        }

Definition at line 58 of file GMEOLEError.h.

#define SHOW_ERROR (   z)
Value:
{ \
                AfxThrowOleDispatchException(ID_ERROR_NOT_FOUND, \
                        (z)); \
        }

Definition at line 64 of file GMEOLEError.h.

#define THROW_IF_BOOL (   x,
 
)
Value:
if ( (x)) { \
                throw y; \
        }

Definition at line 75 of file GMEOLEError.h.

#define THROW_IF_NULL (   x,
 
)
Value:
if ( (!x)) { \
                throw y; \
        }

Definition at line 70 of file GMEOLEError.h.