[#BloombergLP-bdlt-EpochUtil-convertToDatetimeInterval-09]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlt.adoc[bdlt]::xref:BloombergLP/bdlt/EpochUtil.adoc[EpochUtil]::convertToDatetimeInterval
:relfileprefix: ../../../
:mrdocs:

If `datetime &hyphen; epoch() &gt;&equals; DatetimeInterval()`, load into the specified `result` the relative time converted to a `DatetimeInterval`, computed as the difference between the specified absolute `datetime` and the epoch, and return 0&period; Otherwise, return a non&hyphen;zero value (with no effect on `result`)&period;

== Synopsis

Declared in `&lt;bdlt&lowbar;epochutil&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
static
int
convertToDatetimeInterval(
    xref:BloombergLP/bdlt/DatetimeInterval.adoc[DatetimeInterval]* result,
    xref:BloombergLP/bdlt/Datetime.adoc[Datetime] const& datetime);
----

== Description

DEPRECATED&colon; Use `convertToDatetimeInterval(datetime)` instead&period;


[.small]#Created with https://www.mrdocs.com[MrDocs]#
