Fawkes API
Fawkes Development Version
|
#include <>>
Public Member Functions | |
LockQueue () | |
Constructor. More... | |
LockQueue (const LockQueue< Type > &ll) | |
Copy constructor. More... | |
virtual | ~LockQueue () |
Destructor. More... | |
void | lock () const |
Lock queue. More... | |
bool | try_lock () const |
Try to lock queue. More... | |
void | unlock () const |
Unlock list. More... | |
RefPtr< Mutex > | mutex () const |
Get access to the internal mutex. More... | |
void | push_locked (const Type &x) |
Push element to queue with lock protection. More... | |
void | pop_locked () |
Pop element from queue with lock protection. More... | |
void | clear () |
Clear the queue. More... | |
Queue with a lock. This class provides a queue that has an intrinsic lock. The lock can be applied with the regular locking methods.
Definition at line 50 of file lock_queue.h.
fawkes::LockQueue< Type >::LockQueue |
Constructor.
Definition at line 103 of file lock_queue.h.
fawkes::LockQueue< Type >::LockQueue | ( | const LockQueue< Type > & | ll | ) |
|
virtual |
Destructor.
Definition at line 114 of file lock_queue.h.
void fawkes::LockQueue< Type >::clear |
void fawkes::LockQueue< Type >::lock |
Lock queue.
Definition at line 120 of file lock_queue.h.
Referenced by firevision::FuseClient::loop(), SkillerExecutionThread::loop(), fawkes::ConnectionDispatcher::on_connection_died(), fawkes::LockQueue< ClientData >::pop_locked(), fawkes::LockQueue< ClientData >::push_locked(), firevision::FuseNetworkTransceiver::recv(), firevision::FuseNetworkTransceiver::send(), fawkes::FawkesNetworkServerClientThread::set_clid(), fawkes::LockQueue< ClientData >::unlock(), and fawkes::LockQueue< ClientData >::~LockQueue().
|
inline |
Get access to the internal mutex.
Can be used with MutexLocker.
Definition at line 80 of file lock_queue.h.
Referenced by oprs_protobuf::OpenPRSProtobuf::oprs_pb_events_pending(), and oprs_protobuf::OpenPRSProtobuf::oprs_pb_process().
void fawkes::LockQueue< Type >::pop_locked |
Pop element from queue with lock protection.
Definition at line 150 of file lock_queue.h.
void fawkes::LockQueue< Type >::push_locked | ( | const Type & | x | ) |
Push element to queue with lock protection.
x | element to add |
Definition at line 141 of file lock_queue.h.
Referenced by firevision::FuseClient::enqueue(), and firevision::FuseClient::enqueue_and_wait().
bool fawkes::LockQueue< Type >::try_lock |
Try to lock queue.
Definition at line 127 of file lock_queue.h.
Referenced by fawkes::LockQueue< ClientData >::lock().
void fawkes::LockQueue< Type >::unlock |
Unlock list.
Definition at line 134 of file lock_queue.h.
Referenced by firevision::FuseClient::loop(), SkillerExecutionThread::loop(), firevision::FuseNetworkTransceiver::recv(), firevision::FuseNetworkTransceiver::send(), fawkes::FawkesNetworkServerClientThread::set_clid(), and fawkes::LockQueue< ClientData >::try_lock().