4 Causes the current thread to yield for a specified amount of time.
14 PRStatus PR_Sleep(PRIntervalTime ticks);
20 :ref:`PR_Sleep` has the following parameter:
23 The number of ticks you want the thread to sleep for (see
24 :ref:`PRIntervalTime`).
30 Calling :ref:`PR_Sleep` with a parameter equivalent to
31 ``PR_INTERVAL_NO_TIMEOUT`` is an error and results in a ``PR_FAILURE``
38 :ref:`PR_Sleep` simply waits on a condition for the amount of time
39 specified. If you set ticks to ``PR_INTERVAL_NO_WAIT``, the thread
42 If ticks is not ``PR_INTERVAL_NO_WAIT``, :ref:`PR_Sleep` uses an existing
43 lock, but has to create a new condition for this purpose. If you have
44 already created such structures, it is more efficient to use them
47 Calling :ref:`PR_Sleep` with the value of ticks set to
48 ``PR_INTERVAL_NO_WAIT`` simply surrenders the processor to ready threads
49 of the same priority. All other values of ticks cause :ref:`PR_Sleep` to
50 block the calling thread for the specified interval.
52 Threads blocked in :ref:`PR_Sleep` are interruptible.