VoiceMan
Public Member Functions | List of all members
ConfigFileValueTypeException Class Reference

The exception class to notify about parameter value type mismatch. More...

Inheritance diagram for ConfigFileValueTypeException:
VoicemanException

Public Member Functions

 ConfigFileValueTypeException (const std::string &descr)
 The constructor. More...
 
std::string getMessage () const
 Returns exception description. More...
 
void makeLogReport (int level) const
 Makes report to logging system. More...
 
virtual ~ConfigFileValueTypeException ()
 The destructor.
 
- Public Member Functions inherited from VoicemanException
 VoicemanException ()
 The default constructor.
 
virtual ~VoicemanException ()
 The destructor.
 

Detailed Description

This class notifies user about all errors in value type checking procedure. All parameters in configuration file must be checked for type matching automatically to simplify parsed values processing.

See also
ConfigFile ConfigFileException

Constructor & Destructor Documentation

ConfigFileValueTypeException::ConfigFileValueTypeException ( const std::string &  descr)
inline
Parameters
[in]descrThe error description

Member Function Documentation

std::string ConfigFileValueTypeException::getMessage ( ) const
inlinevirtual

This method generates single line description of the error object. returned string can be printed to console or to log as error report.

Returns
The single-line error description

Implements VoicemanException.

void ConfigFileValueTypeException::makeLogReport ( int  level) const
inlinevirtual

This function writes to log a report about error object. It may be not exactly the same value as produced by getMessage() method. The level of message must be specified, because the same error can have different levels in different situations. For example, configuration file error is critical error during server startup process due to to requirement have first configuration information, but be just a usual error in configuration reloading, because in this case server can successfully use its previous configuration data.

Parameters
levelThe level of error log report

Implements VoicemanException.