Account
Beamlib 3.3.4 This is the Beam C++ class library. |
Error return class. This class is used to return the error status from a function. It encapsulates an integer error number and a string. More...
#include <BError.h>

Public Member Functions | |
BError (int errNo=ErrorOk, BString errStr="") | |
Create object. | |
BError (BString errStr) | |
Create with error set and error string. | |
BError | copy () |
Return an independant copy. | |
BError & | set (int errNo, BString errStr="") |
Set error number and message. | |
BError & | clear () |
Clear the error. | |
BError & | setError (BString errStr="") |
Set error type ERROR with optional message. | |
BString | getString () const |
Get error message. | |
int | getNumber () const |
Get The error number. | |
int | num () const |
Get The error number. | |
const char * | str () const |
Return a char* string. | |
int | getErrorNo () const |
Get The error number. | |
operator int () const | |
Return error number. | |
Detailed Description
Error return class. This class is used to return the error status from a function. It encapsulates an integer error number and a string.
An error number of ErrorOk (0) indicates no error, a value of ErrorMisc (1) indicates some error and a value of ErrorWarning (2) indiactes a warning. Specific error numbers are defeined in BErrorNum. System low level errors (errno) are defined by negativer values. Specific application errors are those above the value 64.
Constructor & Destructor Documentation
◆ BError() [1/2]
◆ BError() [2/2]
BError::BError | ( | BString | errStr | ) |
Create with error set and error string.
Member Function Documentation
◆ copy()
BError BError::copy | ( | ) |
Return an independant copy.
◆ set()
◆ clear()
BError & BError::clear | ( | ) |
Clear the error.
◆ setError()
◆ getString()
BString BError::getString | ( | ) | const |
Get error message.
◆ getNumber()
int BError::getNumber | ( | ) | const |
Get The error number.
◆ num()
int BError::num | ( | ) | const |
Get The error number.
◆ str()
const char * BError::str | ( | ) | const |
Return a char* string.
◆ getErrorNo()
int BError::getErrorNo | ( | ) | const |
Get The error number.
◆ operator int()
| inline |
Return error number.
The documentation for this class was generated from the following files:
Generated by