Main Page   Class Hierarchy   Compound List   File List   Compound Members  

PLib::Error Class Reference

A class to print and handle error messages. More...

#include <error.h>

List of all members.

Public Methods

 Error ()
 Error (const char *s)
 ~Error ()
void warning (const char *msg=0)
void nonfatal (const char *msg=0)
void fatal (const char *=0)
void memory (const void *=0)


Detailed Description

A class to print and handle error messages.

This class prints error messages in a standard way.

Author:
Philippe Lavoie
Date:
4 October 1996

Definition at line 111 of file error.h.


Constructor & Destructor Documentation

PLib::Error::Error const char *    title
 

constructor Description:.

Parameters:
title  the title of the routine where the error occurs
Returns:
Warning:
Author:
Philippe Lavoie
Date:
24 January 1997

Definition at line 48 of file error.cpp.


Member Function Documentation

void PLib::Error::fatal const char *    msg = 0
 

reports a fatal error Reports a fatal error. If the \verb.DEBUG_MATRIX. flag has been set then the routine starts an infinte loop. An exit(1) is executed otherwise.

The usual call to this function is made through the $\ll$ operator, {i.e.} \begin{verbatim} Error error("routine name") ; error << "A fatal error occured " ; error.fatal() ; \end{verbatim}

Parameters:
msg  a message to report
Returns:
Warning:
Author:
Philippe Lavoie
Date:
24 January 1997

Definition at line 137 of file error.cpp.

void PLib::Error::memory const void *    p = 0
 

reports a memory allocation error Reports a memory allocation error. If the DEBUG_PLIB flag has been set then the routine starts an infinte loop. An exit(1) is executed otherwise.

The usual call to this function is made through the operator>> , {i.e.} \begin{verbatim} Error error("variable name") ; float* var = new float[bigSize] ; error.memory(var) ; \end{verbatim}

Parameters:
p  the pointer to test
Returns:
Warning:
Author:
Philippe Lavoie
Date:
24 January 1997

Definition at line 169 of file error.cpp.

void PLib::Error::warning const char *    msg = 0
 

reports a warning error message The usual call to this function is made through the $\ll$ operator, {i.e.} \begin{verbatim} Error error("routine name") ; error << "An error occured " ; error.warning() ; \end{verbatim}.

Parameters:
msg  the message to report
Returns:
Warning:
Author:
Philippe Lavoie
Date:
24 January 1997

Definition at line 109 of file error.cpp.


The documentation for this class was generated from the following files:
Generated on Tue Jun 24 13:26:59 2003 for NURBS++ by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002