121 [[nodiscard]] std::string_view
get(
const char*
format =
"%02d-%02d %02d:%02d:%02d.%03d",
bool use_utc =
false);
124 void format_full_timestamp(
const char*
format, std::chrono::system_clock::time_point now,
bool use_utc,
int ms);
126 void update_milliseconds(
int ms);
128 alignas(64) std::atomic<int64_t> last_sec_{0};
131 size_t buffer_len_{0};
132 size_t ms_offset_{0};
std::string_view get(const char *format="%02d-%02d %02d:%02d:%02d.%03d", bool use_utc=false)
Returns a std::string_view of the current formatted timestamp.
~CachedTimestamp()
Destructor.
CachedTimestamp()
Constructs a CachedTimestamp with an empty internal cache.
Platform-independent macro definitions for the VLink library.
#define VLINK_EXPORT
定义 macros.h:85