|
Display_Lib_RPI 2.7.0
A C++ Library to connect electronic displays to Linux single board computers.
|
Name space for time related utilities. More...
Functions | |
| std::string | UTC_string () |
Name space for time related utilities.
| std::string rdlib_time::UTC_string | ( | ) |
@brief Returns the current UTC time as a formatted string.
@return std::string containing the current UTC time in "yyyy-mm-dd hh:mm:ss UTC" format.
@note Requires C++20 for std::format and std::chrono::floor support.
@details Uses std::chrono::system_clock to get the current time, truncates
to second precision with std::chrono::floor, then formats the result
using std::format with the ISO 8601 date and time specifiers.
std::string time = UTC_string();
Returns e.g. "2026-06-02 19:13:21 UTC"