MDSTk Libraries  1.1.0
Medical Data Segmentation Toolkit
Classes | Namespaces | Defines
mdsError.h File Reference

Medical Data Segmentation Toolkit (MDSTk)
Copyright (c) 2003-2005 by Michal Spanel
. More...

#include "mdsFullException.h"

Classes

class  mds::base::CError
 Class encapsulating an error origin and description. More...

Namespaces

namespace  mds
 

Medical Data Segmentation Toolkit (MDSTk)
Copyright (c) 2003-2005 by Michal Spanel


namespace  mds::base

Defines

#define MDS_CATCH_ERROR(ModuleName)
 Catch block for handling the CError exception.
#define MDS_ERROR(Name)   mds::base::CError(Name, __FILE__, __LINE__)
 Macro that creates an error object with 'Name' as an description.
#define MDS_THROW_ERROR(Name)   throw mds::base::CError(Name, __FILE__, __LINE__)
 Creates and throws an error with 'Name' as an description.

Detailed Description

Medical Data Segmentation Toolkit (MDSTk)
Copyright (c) 2003-2005 by Michal Spanel
.

Author: Michal Spanel, spanel@fit.vutbr.cz
Date: 2003/10/27

Id:
mdsError.h 1863 2010-08-31 20:40:15Z spanel

Description:


Define Documentation

#define MDS_CATCH_ERROR (   ModuleName)
Value:
catch( const mds::base::CError& Error ) \
    { \
        MDS_LOG(Error); \
        MDS_CERR('<' << ModuleName << "> Error: see log for details, termintating ..." << std::endl); \
        abort(); \
    }

Catch block for handling the CError exception.

  • Writes info about it to the global log and cerr.
  • Terminates the program!
#define MDS_ERROR (   Name)    mds::base::CError(Name, __FILE__, __LINE__)

Macro that creates an error object with 'Name' as an description.

  • File and line parameters acquired from a compiler.
#define MDS_THROW_ERROR (   Name)    throw mds::base::CError(Name, __FILE__, __LINE__)

Creates and throws an error with 'Name' as an description.

  • File and line parameters acquired from a compiler.