boost::logging::profile::compute_for_filter< filter_type > Struct Template Reference

Allows you to compute profiling for your filter class. More...

List of all members.


Detailed Description

template<class filter_type>
struct boost::logging::profile::compute_for_filter< filter_type >

Allows you to compute profiling for your filter class.

#include <boost/logging/profile.hpp>

In case you want to profile your filter, there's just one requirement:

To 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) 

See also:
compute_for_logger
Examples:

use_profiler.cpp.


The documentation for this struct was generated from the following file:

Copyright John Torjo © 2007
Have a question/ suggestion/ comment? Send me feedback