CVM Class Library  8.1
This C++ class library encapsulates concepts of vector and different matrices including square, band, symmetric and hermitian ones in Euclidean space of real and complex numbers.
 All Classes Files Functions Variables Typedefs Friends Macros Pages
Public Member Functions | Static Public Member Functions | Protected Attributes | List of all members
cvmexception Class Reference

Library exception class. More...

#include <cvm.h>

Inheritance diagram for cvmexception:
Inheritance graph
[legend]
Collaboration diagram for cvmexception:
Collaboration graph
[legend]

Public Member Functions

 cvmexception ()
 Default constructor.
CVM_API cvmexception (int nCause,...)
 Exception constructor.
CVM_API cvmexception (const cvmexception &e)
 Exception copy constructor.
virtual ~cvmexception () throw ()
 Exception destructor, inherited from std::exception.
int cause () const
 Exception Code.
const char * what () const override throw ()
 Exception message.

Static Public Member Functions

static int getNextCause ()
 Next available error code.
static bool add (int nNewCause, const char *szNewMessage)
 Add new user-defined exception.

Protected Attributes

int mnCause
 Exception code.
char mszMsg [256]
 Formatted message.

Detailed Description

Library exception class.

Exception class used in the library. Inherited from std::exception.

Definition at line 358 of file cvm.h.

Constructor & Destructor Documentation

cvmexception::cvmexception ( )
inline

Default constructor.

Default constructor (not an error by default).

Definition at line 376 of file cvm.h.

CVM_NAMESPACE_BEG cvmexception::cvmexception ( int  nCause,
  ... 
)
explicit

Exception constructor.

Exception constructor with error code and optional error string (might be formatted for printf).

Parameters
[in]nCauseError code (might be user-defined).
See Also
add()

Definition at line 168 of file globals.cpp.

cvmexception::cvmexception ( const cvmexception e)

Exception copy constructor.

Definition at line 185 of file globals.cpp.

virtual cvmexception::~cvmexception ( ) throw ()
inlinevirtual

Exception destructor, inherited from std::exception.

Definition at line 399 of file cvm.h.

Member Function Documentation

int cvmexception::cause ( ) const
inline

Exception Code.

Returns numerical code for exception thrown.

See Also
CVM_OUTOFMEMORY
what()
Returns
Exception Code

Definition at line 409 of file cvm.h.

const char* cvmexception::what ( ) const throw ()
inlineoverride

Exception message.

Returns formatted exception message.

See Also
cause()
Returns
Exception message

Definition at line 420 of file cvm.h.

static int cvmexception::getNextCause ( )
inlinestatic

Next available error code.

Next available error code to create user-defined ones.

See Also
add()
Returns
Error code

Definition at line 431 of file cvm.h.

static bool cvmexception::add ( int  nNewCause,
const char *  szNewMessage 
)
inlinestatic

Add new user-defined exception.

Creates user-defined exception for library extensions, see programmer's reference for detailes.

See Also
getNextCause()
Parameters
[in]nNewCauseNew code.
[in]szNewMessageNew message.
Returns
bool - true if succeeded, false otherwise

Definition at line 444 of file cvm.h.

Here is the call graph for this function:

Member Data Documentation

int cvmexception::mnCause
protected

Exception code.

Definition at line 361 of file cvm.h.

char cvmexception::mszMsg[256]
mutableprotected

Formatted message.

Definition at line 362 of file cvm.h.


The documentation for this class was generated from the following files: