Lines Matching full:mutex
18 * Encapsulate a mutex for thread synchronization.
21 #include "Mutex.h"
30 ** Function: Mutex
37 Mutex::Mutex ()
43 ALOGE ("Mutex::Mutex: fail init; error=0x%X", res);
50 ** Function: ~Mutex
57 Mutex::~Mutex ()
62 ALOGE ("Mutex::~Mutex: fail destroy; error=0x%X", res);
71 ** Description: Block the thread and try lock the mutex.
76 void Mutex::lock ()
81 ALOGE ("Mutex::lock: fail lock; error=0x%X", res);
90 ** Description: Unlock a mutex to unblock a thread.
95 void Mutex::unlock ()
100 ALOGE ("Mutex::unlock: fail unlock; error=0x%X", res);
109 ** Description: Try to lock the mutex.
111 ** Returns: True if the mutex is locked.
114 bool Mutex::tryLock ()
119 ALOGE ("Mutex::tryLock: error=0x%X", res);
129 ** Description: Get the handle of the mutex.
131 ** Returns: Handle of the mutex.
134 pthread_mutex_t* Mutex::nativeHandle ()