[#BloombergLP-bdlt-EpochUtil-convertToTimeT-05] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlt.adoc[bdlt]::xref:BloombergLP/bdlt/EpochUtil.adoc[EpochUtil]::convertToTimeT :relfileprefix: ../../../ :mrdocs: `convertToTimeT` overloads == Synopses Declared in `<bdlt_epochutil.h>` Return the relative time computed as the difference between the specified absolute `datetime` and the epoch. The behavior is undefined unless `datetime ‐ epoch() >= DatetimeInterval()` and the converted `datetime` can be represented in the destination format on all supported platforms (i.e., the resultant value is representable as a 32‐bit `int`). Note that `datetime` is assumed to use Coordinated Universal Time (UTC) as a reference. Also note that if error detection is desired, the overloaded version that loads the converted `datetime` into a supplied destination object should be used. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- static std::time_t xref:BloombergLP/bdlt/EpochUtil/convertToTimeT-00.adoc[convertToTimeT](xref:BloombergLP/bdlt/Datetime.adoc[Datetime] const& datetime); ---- [.small]#xref:BloombergLP/bdlt/EpochUtil/convertToTimeT-00.adoc[_» more..._]# Load into the specified `result` the relative time computed as the difference between the specified absolute `datetime` and the epoch. Return 0 on success, and a non‐zero value (with no effect on `result`) if `datetime ‐ epoch() < DatetimeInterval()` or `datetime` cannot be represented in the destination format on all supported platforms (i.e., the computed `*result` is not representable as a 32‐bit `int`). Note that `datetime` is assumed to use Coordinated Universal Time (UTC) as a reference. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- static int xref:BloombergLP/bdlt/EpochUtil/convertToTimeT-0f.adoc[convertToTimeT]( std::time_t* result, xref:BloombergLP/bdlt/Datetime.adoc[Datetime] const& datetime); ---- [.small]#xref:BloombergLP/bdlt/EpochUtil/convertToTimeT-0f.adoc[_» more..._]# [.small]#Created with https://www.mrdocs.com[MrDocs]#