#include <boost/logging/profile.hpp>
In case you want to profile your filter, there's just one requirement:
is_enabled()
and be constTo do profiling for a filter, just surround it with compute_for_filter. Example:
Old code
#include <boost/logging/format_fwd.hpp> namespace bl = boost::logging ; typedef bl::filter::no_ts filter; BOOST_DECLARE_LOG_FILTER(g_l_filter, filter) ... BOOST_DEFINE_LOG_FILTER(g_l_filter, filter)
New code
#include <boost/logging/format_fwd.hpp> #include <boost/logging/profile.hpp> namespace bl = boost::logging ; typedef bl::filter::no_ts raw_filter; typedef compute_for_filter<raw_filter>::type filter; BOOST_DECLARE_LOG_FILTER(g_l_filter, filter) ... BOOST_DEFINE_LOG_FILTER(g_l_filter, filter)