Provide conversions between absolute datetimes and epoch‐relative intervals.

Synopsis

Declared in <bdlt_epochutil.h>

struct EpochUtil;

Description

This struct provides a namespace for a suite of non‐primitive functions providing conversions between absolute Datetime values and corresponding relative time intervals with respect to the Unix standard epoch time, returned by the epoch method. These methods are alias‐safe, thread‐safe, and exception‐neutral. Functions are provided for returning converted values by value or through a result pointer.

Type Aliases

Name

Description

TimeT64

Alias for a 64‐bit integer counting UTC seconds from the epoch.

Static Member Functions

Name

Description

convertFromDatetimeInterval

convertFromDatetimeInterval overloads

convertFromTimeInterval

convertFromTimeInterval overloads

convertFromTimeT

convertFromTimeT overloads

convertFromTimeT64

convertFromTimeT64 overloads

convertToDatetimeInterval

convertToDatetimeInterval overloads

convertToTimeInterval

convertToTimeInterval overloads

convertToTimeT

convertToTimeT overloads

convertToTimeT64

convertToTimeT64 overloads

epoch

Return a reference to the Unix epoch (1970‐01‐01 00:00:00).

Created with MrDocs