absl::FormatTime

Formats the given time using the RFC3339_full format in the given time zone.

Synopsis

Declared in <absl/time/time.h>

std::string
FormatTime(
    Time t,
    TimeZone tz);

Description

Convenience functions that format the given time using the RFC3339_full format. The first overload uses the provided TimeZone, while the second uses LocalTimeZone().

Return Value

The formatted time string.

Parameters

NameDescription
tThe time to format.
tzThe time zone to format in.