#include <acestl/collections/message_queue_sequence.hpp>

ACE_Message_Queue to provide an STL input-sequence interface. 
It is used as follows:
using acestl::message_queue_sequence; using stlsoft::auto_buffer; ACE_Message_Queue<ACE_NULL_SYNCH> &mq = . . . // Adapt the message queue into the sequence message_queue_sequence<ACE_NULL_SYNCH> mqs(mq); // Allocate a contiguous buffer, using stlsoft::auto_buffer auto_buffer<char> buff(mqs.size()); // Block copy into the buffer std::copy(&buff[0], &buff[0] + (buff.size()), mqs.begin());
std algorithms to effect very favourable performance, as described in chapter 31 of Extended STL, volume 1: Collections and Iterators. | Public Types | |
| Types | |
| typedef char | value_type | 
| The value type. | |
| typedef ACE_Message_Queue < ACE_SYNCH_USE > | sequence_type | 
| The sequence type. | |
| typedef message_queue_sequence < ACE_SYNCH_USE > | class_type | 
| The current parameterisation of the type. | |
| typedef size_t | size_type | 
| The size type. | |
| Public Member Functions | |
| message_queue_sequence (sequence_type &mq) | |
| Create an instance representing the given environment variable. | |
| Iteration | |
| iterator | begin () | 
| Begins the iteration. | |
| iterator | end () | 
| Ends the iteration. | |
| Attributes | |
| size_type | size () const | 
| Returns the number of bytes in the message queue. | |
| bool | empty () const | 
| Indicates whethere there are any bytes in the message queue. | |
| Static Public Member Functions | |
| Operations | |
| static char * | fast_copy (iterator f, iterator l, char *o) | 
| static char * | fast_copy (iterator f, size_type n, char *o) | 
| static iterator | fast_copy (char const *f, char const *l, iterator o) | 
| Classes | |
| class | iterator | 
| Iterator type for the message_queue_sequence class template.  More... | |
| typedef char value_type | 
The value type.
| typedef ACE_Message_Queue<ACE_SYNCH_USE> sequence_type | 
The sequence type.
| typedef message_queue_sequence<ACE_SYNCH_USE> class_type | 
The current parameterisation of the type.
| typedef size_t size_type | 
The size type.
| message_queue_sequence | ( | sequence_type & | mq | ) |  [inline, explicit] | 
Create an instance representing the given environment variable.
| iterator begin | ( | ) |  [inline] | 
| iterator end | ( | ) |  [inline] | 
| size_type size | ( | ) | const  [inline] | 
Returns the number of bytes in the message queue.
| bool empty | ( | ) | const  [inline] | 
 1.5.6
 1.5.6