|
CLAW Library (a C++ Library Absolutely Wonderful) 1.5.5
|
Set the level of the next message for logger_system::operator<<(). More...
#include <log_level.hpp>
Public Member Functions | |
| log_level (int lvl) | |
| Constructor. | |
| log_level (int lvl, const std::string &s) | |
| Constructor. | |
| int | get () const |
| Get the level value. | |
| std::string | get_string () const |
| Get the prefix. | |
Private Attributes | |
| const int | m_level |
| Value of the level. | |
| const std::string | m_prefix |
| String used for prefix for the current message. | |
Set the level of the next message for logger_system::operator<<().
Definition at line 57 of file log_level.hpp.
| claw::log_level::log_level | ( | int | lvl | ) |
Constructor.
| lvl | The value of this level. |
Definition at line 46 of file log_level.cpp.
: m_level(lvl) { } // log_level::log_level()
| claw::log_level::log_level | ( | int | lvl, |
| const std::string & | s | ||
| ) |
Constructor.
| lvl | The value of this level. |
| s | The messages prefix. |
Definition at line 58 of file log_level.cpp.
| int claw::log_level::get | ( | ) | const |
Get the level value.
Definition at line 68 of file log_level.cpp.
Referenced by claw::log_system::operator<<(), and claw::log_system::set_level().
{
return m_level;
} // log_level::get()
| std::string claw::log_level::get_string | ( | ) | const |
Get the prefix.
Definition at line 77 of file log_level.cpp.
References claw_gettext.
Referenced by claw::log_system::operator<<().
{
if (m_prefix.empty())
return m_prefix;
else
return claw_gettext(m_prefix.c_str());
} // log_level::get_string()
const int claw::log_level::m_level [private] |
Value of the level.
Definition at line 67 of file log_level.hpp.
const std::string claw::log_level::m_prefix [private] |
String used for prefix for the current message.
Definition at line 70 of file log_level.hpp.
1.7.3