Public Member Functions | List of all members
spdlog::details::F_formatter Class Referencefinal

#include <pattern_formatter.h>

Inheritance diagram for spdlog::details::F_formatter:
spdlog::details::flag_formatter

Public Member Functions

 F_formatter (padding_info padinfo)
 
void format (const details::log_msg &msg, const std::tm &, fmt::memory_buffer &dest) override
 
- Public Member Functions inherited from spdlog::details::flag_formatter
 flag_formatter (padding_info padinfo)
 
 flag_formatter ()=default
 
virtual ~flag_formatter ()=default
 

Additional Inherited Members

- Protected Attributes inherited from spdlog::details::flag_formatter
padding_info padinfo_
 

Detailed Description

Definition at line 508 of file pattern_formatter.h.

Constructor & Destructor Documentation

spdlog::details::F_formatter::F_formatter ( padding_info  padinfo)
inlineexplicit

Definition at line 511 of file pattern_formatter.h.

512  : flag_formatter(padinfo){};

Member Function Documentation

void spdlog::details::F_formatter::format ( const details::log_msg msg,
const std::tm &  ,
fmt::memory_buffer dest 
)
inlineoverridevirtual

Implements spdlog::details::flag_formatter.

Definition at line 514 of file pattern_formatter.h.

515  {
516  auto ns = fmt_helper::time_fraction<std::chrono::nanoseconds>(msg.time);
517  if (padinfo_.enabled())
518  {
519  const size_t field_size = 9;
520  scoped_pad p(field_size, padinfo_, dest);
521  fmt_helper::pad9(static_cast<size_t>(ns.count()), dest);
522  }
523  else
524  {
525  fmt_helper::pad9(static_cast<size_t>(ns.count()), dest);
526  }
527  }
void msg(const char *fmt,...)
Definition: message.cpp:107
uint count() const
Definition: qasciidict.h:55
void pad9(T n, fmt::basic_memory_buffer< char, Buffer_Size > &dest)
Definition: fmt_helper.h:102
p
Definition: test.py:223
QAsciiDict< Entry > ns

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