7#pragma warning(disable: 4714)
12#include <FMEThirdPartyWarningsDisable.h>
14#include <boost/log/common.hpp>
15#include <boost/log/expressions.hpp>
16#include <boost/log/keywords/format.hpp>
17#include <boost/log/keywords/filter.hpp>
18#include <boost/log/keywords/severity.hpp>
19#include <boost/log/keywords/channel.hpp>
20#include <boost/log/utility/setup/console.hpp>
21#include <boost/log/utility/setup/file.hpp>
22#include <boost/log/utility/setup/common_attributes.hpp>
23#include <boost/log/utility/setup/filter_parser.hpp>
24#include <boost/log/utility/setup/formatter_parser.hpp>
25#include <boost/log/utility/exception_handler.hpp>
26#include <FMEThirdPartyWarningsRestore.h>
39 template<
typename CharT,
typename TraitsT>
42 static const char*
const str[] =
51 if (level < (
sizeof(
str) /
sizeof(*
str))) {
64 typedef boost::log::sources::severity_channel_logger<SeverityLevel>
Logger;
65 typedef boost::log::sources::severity_channel_logger_mt<SeverityLevel>
ThreadSafeLogger;
67 typedef boost::log::sinks::sink
Sink;
70 namespace keywords = boost::log::keywords;
72 using boost::log::add_console_log;
73 using boost::log::add_file_log;
74 using boost::log::parse_formatter;
75 using boost::log::parse_filter;
76 using boost::log::formatter;
77 using boost::log::filter;
79 template<
typename SinkType>
82 auto core = boost::log::core::get();
89#define LOG_WITH_SEVERITY BOOST_LOG_SEV
90#define LOG_DEBUG(logger) LOG_WITH_SEVERITY(logger, ::scl::Debug)
91#define LOG_INFO(logger) LOG_WITH_SEVERITY(logger, ::scl::Info)
92#define LOG_WARNING(logger) LOG_WITH_SEVERITY(logger, ::scl::Warning)
93#define LOG_ERROR(logger) LOG_WITH_SEVERITY(logger, ::scl::Error)
94#define LOG_CRITICAL(logger) LOG_WITH_SEVERITY(logger, ::scl::Critical)
99 template<
typename LoggerType, SeverityLevel level>
103 template<
typename ConstructionMsgType,
typename DestructionMsgType>
118 std::string destructionMsg;
#define SEVERITYCHANNELLOGGING_EXPORT
#define LOG_WITH_SEVERITY
ScopedLog(LoggerType &logger_, const ConstructionMsgType &creationMsg, const DestructionMsgType &destructionMsg_)
Target mlrange_cast(Source arg)
Generic version of checked ML casts.
MLCSO_EXPORT void level(CSO *cso)
Determines the normal and the center of gravity of the given CSO.
boost::shared_ptr< Sink > SinkPtr
boost::log::sinks::sink Sink
SEVERITYCHANNELLOGGING_EXPORT void initialize()
boost::log::sources::severity_channel_logger_mt< SeverityLevel > ThreadSafeLogger
boost::log::sources::severity_channel_logger< SeverityLevel > Logger
std::basic_ostream< CharT, TraitsT > & operator<<(std::basic_ostream< CharT, TraitsT > &stream, SeverityLevel level)
BOOST_LOG_ATTRIBUTE_KEYWORD(severity, "Severity", SeverityLevel)
void remove_log(boost::shared_ptr< SinkType > sink)