Cantera 2.6.0

Public Member Functions | List of all members
NoExitLogger Class Reference
Diagnostic Output » Writing messages to the screen

Logger that doesn't exit when an error is thrown. More...

`#include <NoExitLogger.h>`

Inheritance diagram for NoExitLogger:
[legend]
Collaboration diagram for NoExitLogger:
[legend]

## Public Member Functions
virtual void | error (const std::string &msg)
| Write an error message and quit. More...
Public Member Functions inherited from Logger
| Logger ()
| Constructor - empty. More...
virtual | ~Logger ()
| Destructor - empty. More...
virtual void | write (const std::string &msg)
| Write a log message. More...
virtual void | writeendl ()
| Write an end of line character and flush output. More...
virtual void | warn (const std::string &warning, const std::string &msg)
| Write a warning message. More...
virtual void | error (const std::string &msg)
| Write an error message and quit. More...

## Detailed Description

Logger that doesn't exit when an error is thrown.

Definition at line 15 of file NoExitLogger.h.

## Constructor & Destructor Documentation

## ◆ NoExitLogger()

NoExitLogger | ( |  | ) |
| inline

Definition at line 17 of file NoExitLogger.h.

## ◆ ~NoExitLogger()

virtual ~NoExitLogger | ( |  | ) |
| inline virtual

Definition at line 18 of file NoExitLogger.h.

## Member Function Documentation

## ◆ error()

virtual void error | ( | const std::string & | msg | ) |
| inline virtual

Write an error message and quit.

The default behavior is to write to the standard error stream, and then call exit(). Note that no end-of-line character is appended to the message, and so if one is desired it must be included in the string. Note that this default behavior will terminate the application Cantera is invoked from (MATLAB, Excel, etc.) If this is not desired, then derive a class and reimplement this method.

Parameters

  msg | Error message to be written to cerr.

Reimplemented from Logger.

Definition at line 20 of file NoExitLogger.h.

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

- NoExitLogger.h