75  typename boost::chrono::duration_units<char_type>::string_type
 
   76    do_get_ratio_prefix(boost::chrono::duration_style style, boost::micro period_tag) 
const override;
 
  118  using boost::call_once;
 
  130                                                   (boost::chrono::duration_style style,
 
  131                                                    boost::micro period_tag) 
const  
  135  if (style == boost::chrono::duration_style::symbol)
 
  140  return Duration_units_default::do_get_ratio_prefix(style, period_tag);
 
  152  using boost::posix_time::microsec_clock;
 
  153  using boost::posix_time::ptime;
 
  154  using boost::chrono::microseconds;
 
  155  using boost::gregorian::date;
 
  156  return microseconds((microsec_clock::universal_time() - ptime(date(1970, 1, 1)))
 
  157                      .total_microseconds());
 
  175  using boost::chrono::symbol_format;
 
  190#if (!defined(__GNUC__)) || (!defined(__x86_64__)) 
  191#  error "An estimation trick below has only been checked with x64 gcc and clang.  Revisit code for other envs." 
  200  const auto sz = val.capacity();
 
  201  return (sz <= 15) ? 0 : sz;
 
Internally used class that enables some of the activities of beautify_chrono_ostream() API.
Duration_units_beautified()
Constructs.
boost::chrono::duration_units< char_type >::string_type do_get_ratio_prefix(boost::chrono::duration_style style, boost::micro period_tag) const override
Returns the prefix string for micro-units; namely the default thing for long-form format ("micro") bu...
static std::locale const  * s_beautified_locale_or_null
Pointer returned by beautified_locale(), pointing to an object allocated exactly once; or null if tha...
static const std::locale & beautified_locale()
Returns a reference to a locale that – if imbued onto an ostream – equals std::locale::classic except...
static boost::once_flag s_beautified_locale_init_flag
Helper to initialize s_beautified_locale_or_null at most once.
virtual ~Null_interface()=0
Boring virtual destructor.
Flow module containing miscellaneous general-use facilities that don't fit into any other Flow module...
void beautify_chrono_ostream(std::ostream *os_ptr)
Sets certain chrono-related formatting on the given ostream that results in a consistent,...
size_t deep_size(const std::string &val)
Estimate of memory footprint of the given value, including memory allocated on its behalf – but exclu...
boost::chrono::microseconds time_since_posix_epoch()
Get the current POSIX (Unix) time as a duration from the Epoch time point.