[#BloombergLP-bsls-TimeInterval-2constructor-07] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bsls.adoc[bsls]::xref:BloombergLP/bsls/TimeInterval.adoc[TimeInterval]::TimeInterval :relfileprefix: ../../../ :mrdocs: Create a time interval from an explicitly convertible `duration`. == Synopsis Declared in `<bsls_timeinterval.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template< class REP_TYPE, class PERIOD_TYPE> constexpr explicit TimeInterval(std::chrono::duration<REP_TYPE, PERIOD_TYPE> const& duration) requires TimeInterval_DurationTraits< REP_TYPE, PERIOD_TYPE>::k_EXPLICIT_CONVERSION_ENABLED; ---- == Description Create a time interval having the value represented by the specified `duration` when the conversion requires an explicit constructor. See the implicit overload for additional details on behavior and preconditions. == Parameters [cols="1,4"] |=== | Name| Description | *duration* | chrono duration to convert |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#