sleepUntil overloads

Synopses

Declared in <bslmt_threadutilimpl_pthread.h>

Suspend execution of the current thread until the specified absoluteTime. Optionally specify clockType which determines the epoch from which the interval absoluteTime is measured (see {Supported Clock‐Types} in the component documentation). Return 0 on success, and a non‐zero value otherwise. The behavior is undefined unless absoluteTime represents a time after January 1, 1970 and before the end of December 31, 9999 (i.e., a time interval greater than or equal to 0, and less than 253,402,300,800 seconds). Note that the actual time suspended depends on many factors including system scheduling and system timer resolution.

static
int
sleepUntil(
    bsls::TimeInterval const& absoluteTime,
    bsls::SystemClockType::Enum clockType = bsls::SystemClockType::e_REALTIME);

Suspend execution of the current thread until the specified absoluteTime. Optionally specify retryOnSignalInterrupt indicating whether to put this thread to sleep again if the operating system interrupts the sleep because of a signal. Optionally specify clockType which determines the epoch from which the interval absoluteTime is measured (see {Supported Clock‐Types} in the component documentation). Return 0 on success, and a non‐zero value otherwise. If retryOnSignalInterrupt is true, an interrupt from a signal will be ignored and the current the thread will be put back to sleep until absoluteTime, otherwise this call will return 0 to the calling thread immediately. The behavior is undefined unless absoluteTime represents a time after January 1, 1970 and before the end of December 31, 9999 (i.e., a time interval greater than or equal to 0, and less than 253,402,300,800 seconds). Note that the actual time suspended depends on many factors including system scheduling and system timer resolution.

static
int
sleepUntil(
    bsls::TimeInterval const& absoluteTime,
    bool retryOnSignalInterrupt = false,
    bsls::SystemClockType::Enum clockType = bsls::SystemClockType::e_REALTIME);

Created with MrDocs