[#BloombergLP-bslmt-ThreadUtil-microSleep]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslmt.adoc[bslmt]::xref:BloombergLP/bslmt/ThreadUtil.adoc[ThreadUtil]::microSleep
:relfileprefix: ../../../
:mrdocs:

Suspend the current thread for at least the specified duration&period;

== Synopsis

Declared in `&lt;bslmt&lowbar;threadutil&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
static
void
microSleep(
    int microseconds,
    int seconds = 0);
----

== Description

Suspend execution of the current thread for a period of at least the specified `microseconds` and the optionally specified `seconds` (relative time), or an interrupting signal is received&period; Note that the actual time suspended depends on many factors including system scheduling and system timer resolution, and may be significantly longer than the time requested&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *microseconds*
| additional microseconds to sleep
| *seconds*
| seconds to sleep&semi; defaults to 0
|===


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