fifo_mutex


A recursive mutex that guarantees order of obtainment using a first-in, first-out (FIFO) scheduling mechanism.

Library

Thread<ToolKit>

Declaration

#include <ospace/thread/rfifo.h>

class os_fifo_mutex

Typedefs

typedef os_fifo_mutex os_recursive_fifo_mutex;

Interface

Constructor
os_fifo_mutex( bool locked )
Constructs a mutex with an initial locked (default false ) state.

Throws: os_thread_toolkit_error

Destructor
~os_fifo_mutex()
Destroys this mutex.
lock
void lock()
Acquires a lock, blocking if necessary. Multiple locks can be obtained by the same thread.

Throws: os_thread_toolkit_error

obtain
void obtain()
Synonym for lock() ; alternative acquisition syntax.

Throws: os_thread_toolkit_error

release
void release()
Synonym for unlock() ; alternative acquisition syntax.

Throws: os_thread_toolkit_error

try_lock
bool try_lock()
Attempts to acquire a lock without blocking. Returns true if successful.

Throws: os_thread_toolkit_error

unlock
void unlock()
Releases a single lock. If a thread owns multiple locks, an equal number of unlocks must occur before the mutex becomes available.

Throws: os_thread_toolkit_error


Copyright©1994-2026 Recursion Software LLC
All Rights Reserved - For use by licensed users only.