26 #ifndef MPD_DB_LOCK_HXX
27 #define MPD_DB_LOCK_HXX
66 assert(db_mutex_holder.
IsNull());
static gcc_pure bool holding_db_lock() noexcept
Does the current thread hold the database lock?
static constexpr ThreadId Null() noexcept
A low-level identification for a thread.
static void db_unlock(void)
Release the global database lock.
bool IsInside() const noexcept
Check if this thread is the current thread.
gcc_pure bool IsNull() const noexcept
Unlock the database while in the current scope.
static void db_lock(void)
Obtain the global database lock.
static gcc_pure const ThreadId GetCurrent() noexcept
Return the current thread's id .
void unlock()
Unlock the mutex now, making the destructor a no-op.