Method Signal():wait() Foundation
Waits for the signal to be posted with optional timeout.
:wait( [<nHSecs>], [<lReset>] ) --> lSignaled
.T. (true) if signal was received, .F. (false) if a timeout occurred.
The :wait() method blocks the calling thread until the Signal object is signaled by another thread calling the :signal() method, or until the specified timeout expires.
This method implements the consumer side of the signal/wait pattern. The calling thread suspends its execution and enters a waiting state. When the signal is posted, the thread is awakened and continues execution.
By default, the signal is automatically reset after a successful wait, ensuring that subsequent calls to :wait() will block until the signal is posted again. This behavior can be controlled with the <lReset> parameter.
If a timeout is specified and expires before the signal is posted, the method returns .F. (false) and the thread continues execution.
If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.