My Project
Public Member Functions | List of all members
ParaEngine::CWinRawMsgQueue Class Reference

the message queue. More...

#include <OSWindows.h>

Inheritance diagram for ParaEngine::CWinRawMsgQueue:
NPL::concurrent_ptr_queue< Data, Condition >

Public Member Functions

 CWinRawMsgQueue (int capacity)
 
- Public Member Functions inherited from NPL::concurrent_ptr_queue< Data, Condition >
 concurrent_ptr_queue (size_type capacity)
 
void SetUseEvent (bool bUseEvent)
 whether to use event to inform consumer when new data items are added to the queue. More...
 
BufferStatus try_push (value_type &item)
 try push to back of the queue. More...
 
BufferStatus try_push_get_front (value_type &item, value_type **ppFrontItem)
 same as try_push, except that it also returns pointer to the front object. More...
 
void push (value_type &data)
 add a data item to the back of the queue. More...
 
void push_front (value_type &data)
 add a data item to the front of the queue. More...
 
bool try_pop (value_type &popped_value)
 
void wait_and_pop (value_type &popped_value)
 
void wait (int nMessageCount=-1)
 simply wait for the next message to arrive. More...
 
value_type peek (size_type nIndex)
 
bool try_pop_at (size_type nIndex, value_type &popped_value)
 pop message at given index. More...
 
value_type * try_front ()
 
bool try_next (value_type **ppValueFront)
 try pop from the front of the queue and return the front object after the pop. More...
 
bool empty () const
 
bool full () const
 
size_type size () const
 Get the number of elements currently stored in the circular_buffer.
 
size_type capacity () const
 Get the number of elements that can be stored in the circular_buffer.
 
void set_capacity (size_type new_capacity)
 Set the max number of elements that can be stored in the circular_buffer.
 

Additional Inherited Members

- Public Types inherited from NPL::concurrent_ptr_queue< Data, Condition >
enum  BufferStatus {
  BufferOverFlow = 0, BufferFull = 1, BufferNormal = 2, BufferEmpty = 3,
  BufferFirst = 3
}
 
- Protected Types inherited from NPL::concurrent_ptr_queue< Data, Condition >
typedef boost::circular_buffer< Data > container_type
 
typedef container_type::size_type size_type
 
typedef container_type::value_type value_type
 
- Protected Attributes inherited from NPL::concurrent_ptr_queue< Data, Condition >
boost::mutex m_mutex
 
Condition m_condition_variable
 
bool m_use_event
 whether to use event to inform consumer when new data items are added to the queue. More...
 
container_type m_container
 

Detailed Description

the message queue.

e.g. CWinRawMsg_ptr msg(new CWinRawMsg(0,0,0,0)); pWinRawMsgQueue->push(msg);


The documentation for this class was generated from the following files: