Alchemy
1.0
A framework to robustly process network messages and structured data
|
Represents a set of fields that provide homogeneous bit-field access to each of the data values. More...
#include <bit_field_array.h>
Public Types | |
typedef user_bit_field_type | bit_field_type |
The Hg type required to properly initialized nested structures to provide the natural bit-field syntax. | |
typedef array_type::const_iterator | const_iterator |
A const iterator to a value_type index. | |
typedef const bit_field_type | const_reference |
Const Reference to an element in the array. | |
typedef array_type::const_reverse_iterator | const_reverse_iterator |
A const reverse iterator to a value_type index. | |
typedef array_type::iterator | iterator |
An iterator to a value_type index. | |
typedef bit_field_type | reference |
Reference to an element in the array. | |
typedef array_type::reverse_iterator | reverse_iterator |
A reverse iterator to a value_type index. | |
typedef BitFieldArray< T, N > | this_type |
An alias for this classes definition. | |
typedef T | user_bit_field_type |
The type of bit-field interface defined by the user to access individual value entries in the array. | |
typedef T::value_type | value_type |
The data type managed by this Array. This is the type of data that will be written to the attached buffer. | |
Public Member Functions | |
BitFieldArray () | |
Default Constructor. | |
BitFieldArray (const BitFieldArray &rhs) | |
Copy Constructor. | |
BitFieldArray (const value_type(&rhs)[N]) | |
Value constructor based on an array of raw integer type data. | |
~BitFieldArray () | |
Destructor. | |
const_reference | at (size_t idx) const |
Accesses the value at the specified index in the array data.. | |
reference | at (size_t idx) |
Accesses the value at the specified index in the array data.. | |
const_reference | back () const |
Accesses the last valid value in the array data.. | |
reference | back () |
Accesses the last valid value in the array data.. | |
iterator | begin () |
Returns an iterator to the first item in the array. | |
const value_type * | data () const |
Returns a pointer to the raw data buffer for the container for reference. | |
value_type * | data () |
Returns a pointer to the raw data buffer for the container for assignment. | |
size_t | data_size () const |
Returns the number of bytes required to hold the entire array of data. | |
bool | empty () const |
Indicates if this container contains 0 elements. | |
iterator | end () |
Returns an iterator to the item one passed the end of the array. | |
const_reference | front () const |
Accesses the first value in the array data.. | |
reference | front () |
Accesses the first value in the array data.. | |
operator reference () | |
Conversion operator to the value_type reference. More... | |
operator value_type () const | |
Value Conversion Operator (value_type) More... | |
BitFieldArray & | operator= (const BitFieldArray &rhs) |
Assignment operator. | |
BitFieldArray & | operator= (const value_type(&rhs)[N]) |
Value Assignment operator (Assigns a raw array of the correct size.) | |
const_reference | operator[] (size_t idx) const |
Accesses the value at the specified index in the array data.. | |
reference | operator[] (size_t idx) |
Accesses the value at the specified index in the array data.. | |
reverse_iterator | rbegin () |
Returns an iterator to the last item of the array moving in reverse. | |
reverse_iterator | rend () |
Returns an iterator to the item one passed the beginning of the array, moving in reverse. | |
size_t | size () const |
Returns the number of elements within the array. | |
Represents a set of fields that provide homogeneous bit-field access to each of the data values.
This object requires a Hg bit-field definition for the type definition of this object. The base integer type that is defined for the bit-field will be used to define the type for allocation of memory for the array.
Each field allocated in the array will accessible either by the base integer type or with the bit-field interface provided supplied to the definition.
Definition at line 49 of file bit_field_array.h.
|
inline |
Conversion operator to the value_type reference.
Definition at line 201 of file bit_field_array.h.
|
inline |
Value Conversion Operator (value_type)
Allows the entire BitSet to be extracted and assigned as a value to the host value type.
Definition at line 214 of file bit_field_array.h.