Static Public Member Functions | Static Public Attributes | List of all members
mf::timestamp::Legacy Struct Reference

#include <formatTime.h>

Static Public Member Functions

static std::string get_time (timeval const &t)
 

Static Public Attributes

static constexpr char const * format {"%d-%b-%Y %H:%M:%S %Z"}
 

Detailed Description

Definition at line 15 of file formatTime.h.

Member Function Documentation

std::string mf::timestamp::Legacy::get_time ( timeval const &  t)
static

Definition at line 23 of file formatTime.cc.

24 {
25  struct tm timebuf;
26  char ts[SIZE];
27  strftime(ts, sizeof(ts), format, localtime_r(&t.tv_sec, &timebuf));
28  return std::string{ts};
29 }
static constexpr char const * format
Definition: formatTime.h:16
std::string string
Definition: nybbler.cc:12

Member Data Documentation

constexpr char const* mf::timestamp::Legacy::format {"%d-%b-%Y %H:%M:%S %Z"}
static

Definition at line 16 of file formatTime.h.


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