[#BloombergLP-bsls-TimeInterval-asDuration] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bsls.adoc[bsls]::xref:BloombergLP/bsls/TimeInterval.adoc[TimeInterval]::asDuration :relfileprefix: ../../../ :mrdocs: Return the value of this time interval as a `std::chrono::duration` object. This function participates in overloading if `DURATION_TYPE` is actually an `std::chrono::duration` instance, and if it has _not_ a floating point representation. The behavior is undefined unless the total number of nanoseconds can be represented using a `DURATION_TYPE`. Note that the return value may be negative. == Synopsis Declared in `<bsls_timeinterval.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<class DURATION_TYPE> constexpr DURATION_TYPE asDuration() const requires TimeInterval_IsDuration<DURATION_TYPE>::value && !TimeInterval_RepTraits<typename DURATION_TYPE::rep>::k_IS_FLOAT; ---- [.small]#Created with https://www.mrdocs.com[MrDocs]#