#include <ThreadSafeQueue.h>
Public Member Functions | |
| ThreadSafeQueue () | |
| virtual | ~ThreadSafeQueue () |
| bool | empty () |
| size_t | size () |
| T | front () |
| const T | front () const |
| T | back () |
| const T | back () const |
| void | push (const T &x) |
| void | pop () |
| T | frontpop () throw (ibrcommon::Exception) |
| T | blockingpop (size_t timeout=0) throw (ibrcommon::Exception) |
| void | unblock () throw () |
| void | reset () throw () |
| LockedQueue< T > | LockedAccess () |
Protected Attributes | |
| std::queue< T > | _queue |
| bool | _unblock |
Definition at line 40 of file ThreadSafeQueue.h.
| ibrcommon::ThreadSafeQueue< T >::ThreadSafeQueue | ( | ) | [inline] |
Definition at line 43 of file ThreadSafeQueue.h.
| virtual ibrcommon::ThreadSafeQueue< T >::~ThreadSafeQueue | ( | ) | [inline, virtual] |
Definition at line 46 of file ThreadSafeQueue.h.
| const T ibrcommon::ThreadSafeQueue< T >::back | ( | ) | const [inline] |
Definition at line 83 of file ThreadSafeQueue.h.
| T ibrcommon::ThreadSafeQueue< T >::back | ( | ) | [inline] |
Definition at line 77 of file ThreadSafeQueue.h.
| T ibrcommon::ThreadSafeQueue< T >::blockingpop | ( | size_t | timeout = 0 |
) | throw (ibrcommon::Exception) [inline] |
Definition at line 117 of file ThreadSafeQueue.h.
Referenced by dtn::core::SQLiteBundleStorage::componentRun(), dtn::core::SimpleBundleStorage::componentRun(), dtn::api::Client::getBundle(), dtn::core::EventSwitch::loop(), and dtn::routing::EpidemicRoutingExtension::run().
| bool ibrcommon::ThreadSafeQueue< T >::empty | ( | ) | [inline] |
Definition at line 50 of file ThreadSafeQueue.h.
Referenced by dtn::core::EventSwitch::componentDown().
| const T ibrcommon::ThreadSafeQueue< T >::front | ( | ) | const [inline] |
Definition at line 70 of file ThreadSafeQueue.h.
| T ibrcommon::ThreadSafeQueue< T >::front | ( | ) | [inline] |
Definition at line 64 of file ThreadSafeQueue.h.
| T ibrcommon::ThreadSafeQueue< T >::frontpop | ( | ) | throw (ibrcommon::Exception) [inline] |
Definition at line 104 of file ThreadSafeQueue.h.
Referenced by dtn::core::EventSwitch::componentDown(), dtn::net::TCPConvergenceLayer::TCPConnection::eventBundleForwarded(), dtn::daemon::ClientHandler::eventBundleForwarded(), dtn::net::TCPConvergenceLayer::TCPConnection::eventBundleRefused(), dtn::daemon::ClientHandler::eventBundleRefused(), dtn::net::TCPConvergenceLayer::TCPConnection::eventConnectionDown(), and dtn::daemon::ClientHandler::eventConnectionDown().
| LockedQueue<T> ibrcommon::ThreadSafeQueue< T >::LockedAccess | ( | ) | [inline] |
Definition at line 154 of file ThreadSafeQueue.h.
| void ibrcommon::ThreadSafeQueue< T >::pop | ( | ) | [inline] |
Definition at line 98 of file ThreadSafeQueue.h.
| void ibrcommon::ThreadSafeQueue< T >::push | ( | const T & | x | ) | [inline] |
Definition at line 90 of file ThreadSafeQueue.h.
Referenced by dtn::routing::EpidemicRoutingExtension::notify(), dtn::net::operator<<(), dtn::daemon::operator<<(), dtn::core::EventSwitch::raiseEvent(), dtn::api::Client::received(), and dtn::routing::EpidemicRoutingExtension::run().
| void ibrcommon::ThreadSafeQueue< T >::reset | ( | ) | throw () [inline] |
Definition at line 148 of file ThreadSafeQueue.h.
| size_t ibrcommon::ThreadSafeQueue< T >::size | ( | ) | [inline] |
Definition at line 57 of file ThreadSafeQueue.h.
| void ibrcommon::ThreadSafeQueue< T >::unblock | ( | ) | throw () [inline] |
Definition at line 141 of file ThreadSafeQueue.h.
Referenced by dtn::core::SQLiteBundleStorage::componentDown(), dtn::core::SimpleBundleStorage::componentDown(), dtn::core::EventSwitch::componentDown(), and dtn::routing::EpidemicRoutingExtension::stopExtension().
std::queue<T> ibrcommon::ThreadSafeQueue< T >::_queue [protected] |
Definition at line 160 of file ThreadSafeQueue.h.
Referenced by ibrcommon::ThreadSafeQueue< Task * >::back(), ibrcommon::ThreadSafeQueue< Task * >::blockingpop(), ibrcommon::ThreadSafeQueue< Task * >::empty(), ibrcommon::ThreadSafeQueue< Task * >::front(), ibrcommon::ThreadSafeQueue< Task * >::frontpop(), ibrcommon::ThreadSafeQueue< Task * >::LockedAccess(), ibrcommon::ThreadSafeQueue< Task * >::pop(), ibrcommon::ThreadSafeQueue< Task * >::push(), and ibrcommon::ThreadSafeQueue< Task * >::size().
bool ibrcommon::ThreadSafeQueue< T >::_unblock [protected] |
Definition at line 161 of file ThreadSafeQueue.h.
Referenced by ibrcommon::ThreadSafeQueue< Task * >::blockingpop(), ibrcommon::ThreadSafeQueue< Task * >::reset(), and ibrcommon::ThreadSafeQueue< Task * >::unblock().
1.6.3