fcml  1.2.2
Public Types | Public Member Functions | List of all members
fcml::ErrorInfo Class Reference

Contains an error message together with error level and error code. More...

#include <fcml_errors.hpp>

Public Types

enum  ErrorLevel {
  EL_ERROR,
  EL_WARN
}
 Error level. More...
 

Public Member Functions

 ErrorInfo ()
 Default constructor. More...
 
 ErrorInfo (const fcml_cstring &message, fcml_ceh_error code=FCML_CEH_GEC_NO_ERROR, ErrorLevel level=EL_ERROR)
 Creates an error for given message and optional error code and level. More...
 
fcml_ceh_error getCode () const
 Gets error code. More...
 
void setCode (fcml_ceh_error code)
 Sets a new error code. More...
 
ErrorLevel getLevel () const
 Gets error level. More...
 
void setLevel (ErrorLevel level)
 Sets error level. More...
 
const fcml_cstringgetMessage () const
 Gets error message. More...
 
void setMessage (const fcml_cstring &message)
 Sets error message. More...
 

Detailed Description

Contains an error message together with error level and error code.

Since
1.1.0

Member Enumeration Documentation

◆ ErrorLevel

Error level.

Since
1.1.0

Constructor & Destructor Documentation

◆ ErrorInfo() [1/2]

fcml::ErrorInfo::ErrorInfo ( )
inline

Default constructor.

Since
1.1.0

◆ ErrorInfo() [2/2]

fcml::ErrorInfo::ErrorInfo ( const fcml_cstring message,
fcml_ceh_error  code = FCML_CEH_GEC_NO_ERROR,
ErrorLevel  level = EL_ERROR 
)
inline

Creates an error for given message and optional error code and level.

Parameters
messageThe error message.
codeThe error code.
levelThe error level.
Since
1.1.0

Member Function Documentation

◆ getCode()

fcml_ceh_error fcml::ErrorInfo::getCode ( ) const
inline

Gets error code.

Returns
The error code.
Since
1.1.0

◆ getLevel()

ErrorLevel fcml::ErrorInfo::getLevel ( ) const
inline

Gets error level.

Returns
The error level.
Since
1.1.0

◆ getMessage()

const fcml_cstring& fcml::ErrorInfo::getMessage ( ) const
inline

Gets error message.

Returns
The error message.
Since
1.1.0

◆ setCode()

void fcml::ErrorInfo::setCode ( fcml_ceh_error  code)
inline

Sets a new error code.

Parameters
codeThe new error code.
Since
1.1.0

◆ setLevel()

void fcml::ErrorInfo::setLevel ( ErrorLevel  level)
inline

Sets error level.

Parameters
levelThe error level.
Since
1.1.0

◆ setMessage()

void fcml::ErrorInfo::setMessage ( const fcml_cstring message)
inline

Sets error message.

Parameters
messageThe error message.
Since
1.1.0

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