Nana C++ Library  

An open-source C++ framework project
The Programmer's Guide 
nana::threads::timed_mutex

Description

The class timed_mutex provides an exclusive ownership non-recursive mutex.

Model of

None

Public base classes

None

Typedefs

native_handle_type  The type of native handle.

Members

timed_mutex() The construction.
~timed_mutex() The destruction.
void lock() Acquires the ownership for the calling thread.
bool try_lock() Attempts to obtain the ownership without blocking. If ownership is not obtained, it returns false.
bool try_lock_for(std::size_t milliseconds) Attempts to obtain the ownership. It returns false, the waiting is timed out.
void unlock() Relases the ownership of the calling thread.
native_handle_type native_handle() Returns the native handle.

File

nana/threads/mutex.hpp

Notes

None

See also

None.


Move to The Nana Programmer's Guide Main Page