|
Equalizer
1.4.1
|
A CommandQueue is a thread-safe queue for command packets. More...
#include <commandQueue.h>
Inheritance diagram for co::CommandQueue:
Collaboration diagram for co::CommandQueue:Public Member Functions | |
| virtual CO_API void | push (Command &packet) |
| Push a command to the queue. | |
| virtual CO_API void | pushFront (Command &packet) |
| Push a command to the front of the queue. | |
| virtual CO_API void | wakeup () |
| Wake up the command queue, pop() will return 0. | |
| virtual CO_API Command * | pop (const uint32_t timeout=LB_TIMEOUT_INDEFINITE) |
| Pop a command from the queue. | |
| virtual CO_API Command * | tryPop () |
| Try to pop a command from the queue. | |
| CO_API bool | isEmpty () const |
| CO_API void | flush () |
| Flush all cached commands. | |
| CO_API size_t | getSize () const |
| LB_TS_VAR (_thread) | |
A CommandQueue is a thread-safe queue for command packets.
Definition at line 30 of file co/commandQueue.h.
| CO_API void co::CommandQueue::flush | ( | ) |
Flush all cached commands.
| CO_API size_t co::CommandQueue::getSize | ( | ) | const |
| CO_API bool co::CommandQueue::isEmpty | ( | ) | const |
true if the command queue is empty, false if not. | virtual CO_API Command* co::CommandQueue::pop | ( | const uint32_t | timeout = LB_TIMEOUT_INDEFINITE | ) | [virtual] |
Pop a command from the queue.
The returned command has to be released after usage.
| timeout | the time in ms to wait for the operation. |
| Exception | on timeout. |
| virtual CO_API void co::CommandQueue::push | ( | Command & | packet | ) | [virtual] |
Push a command to the queue.
| packet | the command packet. |
Reimplemented in eq::CommandQueue.
| virtual CO_API void co::CommandQueue::pushFront | ( | Command & | packet | ) | [virtual] |
Push a command to the front of the queue.
Reimplemented in eq::CommandQueue.
| virtual CO_API Command* co::CommandQueue::tryPop | ( | ) | [virtual] |
Try to pop a command from the queue.
The returned command has to be released after usage.
Reimplemented in eq::CommandQueue.
| virtual CO_API void co::CommandQueue::wakeup | ( | ) | [virtual] |
Wake up the command queue, pop() will return 0.
Reimplemented in eq::CommandQueue.
1.4.1 by
1.7.6.1