Пример #1
0
void trace(unsigned int level, const char *message)
{
    boost::log::trivial::severity_level severity = level_to_boost(level);

    BOOST_LOG_STREAM_WITH_PARAMS(::boost::log::trivial::logger::get(),\
        (::boost::log::keywords::severity = severity)) << message;
}
Пример #2
0
void DefaultLogger::log(LogLevel level, const char *message) const
{
    BOOST_LOG_SCOPED_THREAD_TAG("id", clientId_.c_str());
    BOOST_LOG_STREAM_WITH_PARAMS(boost::log::trivial::logger::get(),
                                (boost::log::keywords::severity = (boost::log::trivial::severity_level)level)) << message;
}