Alchemy
1.0
A framework to robustly process network messages and structured data
|
The MsgView object to manage structured access over an opaque buffer. More...
#include <msg_view.h>
Public Member Functions | |
msg_view () | |
Default constructor. | |
template<size_t SizeT> | |
msg_view (std::array< byte_t, SizeT > &data) | |
Value constructor. More... | |
msg_view (std::vector< byte_t > &data) | |
Value constructor. More... | |
msg_view (const byte_t *pData, size_t length) | |
Value constructor. More... | |
iterator | begin () |
Returns an iterator to the first item in the array. | |
iterator | end () |
Returns an iterator to the item one passed the end of the array. | |
size_t | size () const |
Returns the number of valid objects managed by this array structure. | |
Static Public Attributes | |
static const bool | k_has_dynamic = has_dynamic<format_type>::value |
Indicates if the format of this message contains fields that are potentially dynamically allocated. | |
Protected Attributes | |
raw_pointer | m_pFirst |
A pointer to the first element. | |
raw_pointer | m_pLast |
A pointer to the last element + 1. | |
The MsgView object to manage structured access over an opaque buffer.
Definition at line 27 of file msg_view.h.
|
inline |
Value constructor.
Create a view from an array of bytes.
view | A reference to an array of bytes, to which this view will be mapped. |
Definition at line 81 of file msg_view.h.
|
inline |
Value constructor.
Create a view from an vector of bytes.
view | A reference to a vector of bytes, to which this view will be mapped. |
Definition at line 100 of file msg_view.h.
|
inline |
Value constructor.
Create a view from an existing array of bytes.
pData | A pointer to an array of bytes, to which this view will be mapped. |
length | The number of bytes in the buffer. |
Definition at line 120 of file msg_view.h.