[#BloombergLP-bslmt-Latch-timedWait-04] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslmt.adoc[bslmt]::xref:BloombergLP/bslmt/Latch.adoc[Latch]::timedWait :relfileprefix: ../../../ :mrdocs: Block until the number of events that this latch is waiting for reaches 0, or until the specified `absTime` timeout expires. Return 0 on success, `e_TIMED_OUT` on timeout, and a non‐zero value different from `e_TIMED_OUT` if an error occurs. Errors are unrecoverable. After an error, the latch may be destroyed, but any other use has undefined behavior. `absTime` is an _absolute_ time represented as an interval from some epoch as determined by the clock specified at construction (see {Supported Clock‐Types} in the component‐level documentation). Note that a return value of 0 does not guarantee this object is safe to destroy. == Synopsis Declared in `<bslmt_latch.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- int timedWait(xref:BloombergLP/bsls/TimeInterval.adoc[bsls::TimeInterval] const& absTime); ---- [.small]#Created with https://www.mrdocs.com[MrDocs]#