mozilla::Monitor

mozilla::Monitor is a bare wrapper around PRMonitor. Please see Introduction_to_NSPR for a high-level summary of its semantics.

Methods

Enter()

Enter the monitor.

Exit()

Exit the monitor.

Wait()

 

nsresult Wait(
    in PRIntervalTime interval = PR_INTERVAL_NO_TIMEOUT
);

Wait on this monitor until it is Notifyed.

 

Notify()

 

nsresult Notify(void);

Notify one thread waiting on this monitor.

 

NotifyAll()

 

nsresult NotifyAll(void);

Notify all threads waiting on this monitor.

 

AssertCurrentThreadIn()

Assert that the current thread is in this monitor. Does not incur a runtime penalty in optimized builds.

AssertNotCurrentThreadIn()

Assert that the current thread is not in this monitor. Does not incur a runtime penalty in optimized builds.

See also

 

 

 

Document Tags and Contributors

Contributors to this page: cgj
Last updated by: cgj,