Public Member Functions | |
high_precision_time_t (const hold_string_type &format) | |
void | configure (const hold_string_type &str) |
configure through script |
#include <boost/logging/format/formatter/high_precision_time.hpp>
Internally, it uses boost::date_time::microsec_time_clock. So, our precision matches this class.
The format can contain escape sequences: $dd - day, 2 digits $MM - month, 2 digits $yy - year, 2 digits $yyyy - year, 4 digits $hh - hour, 2 digits $mm - minute, 2 digits $ss - second, 2 digits $mili - milliseconds $micro - microseconds (if the high precision clock allows; otherwise, it pads zeros) $nano - nanoseconds (if the high precision clock allows; otherwise, it pads zeros)
Example:
high_precision_time("$mm:$ss:$micro");
convert | [optional] In case there needs to be a conversion between std::(w)string and the string that holds your logged message. See convert_format. For instance, you might use a cached_string class (see optimize namespace). |
boost::logging::formatter::high_precision_time_t< convert >::high_precision_time_t | ( | const hold_string_type & | format | ) | [inline] |
constructs a high_precision_time object
void boost::logging::formatter::high_precision_time_t< convert >::configure | ( | const hold_string_type & | str | ) | [inline, virtual] |
configure through script
the string = the time format
Reimplemented from boost::logging::manipulator::is_generic.