Alchemy
1.0
A framework to robustly process network messages and structured data
|
A template to adapt all field types to the Datum assignment. More...
#include <data_proxy.h>
Public Member Functions | |
DataProxy () | |
Default Constructor. | |
DataProxy (const DataProxy &proxy) | |
Copy Constructor. More... | |
DataProxy (const datum_type &datum) | |
Value Constructor: Construct a proxy directly from a datum instance. More... | |
operator reference () | |
Conversion operator to a base Datum Type reference. More... | |
operator value_type () const | |
Value Conversion Operator (value_type) More... | |
DataProxy & | operator= (const datum_type &value) |
Value assignment. | |
DataProxy & | operator= (value_type value) |
Value assignment. | |
Public Member Functions inherited from Hg::Datum< kt_idx, format_t > | |
Datum () | |
Default Constructor. | |
Datum (Datum &datum) | |
Copy Constructor. More... | |
void | clear () |
Zeros the datum. | |
bool | equivalent (const value_type &rhs) const |
Indicates equivalency for a value_type and this Datum's value. More... | |
const value_type & | get () const |
Returns the current value of this Datum. More... | |
value_type & | get () |
Returns a reference to the value managed in this datum. | |
bool | less (const value_type &rhs) const |
Compares a value_type against this Datum's value for less-than relationship. More... | |
operator value_type () const | |
Operator to value_type. More... | |
bool | operator!= (const value_type &rhs) const |
Inequality Value Comparison (value_type) More... | |
bool | operator< (const value_type &rhs) const |
less Than Value Comparison (value_type) More... | |
bool | operator<= (const value_type &rhs) const |
less Than or equal Value Comparison (value_type) More... | |
Datum & | operator= (const Datum &rhs) |
Assignment Operator. More... | |
Datum & | operator= (value_type rhs) |
Assignment Operator (value_type) More... | |
bool | operator== (const value_type &rhs) const |
Equality Value Comparison (value_type) More... | |
bool | operator> (const value_type &rhs) const |
Greater Than Value Comparison (value_type) More... | |
bool | operator>= (const value_type &rhs) const |
Greater Than or equal Value Comparison (value_type) More... | |
void | set (const value_type &value) |
Updates the value of this Datum. More... | |
Public Member Functions inherited from Hg::detail::FieldTypes< FieldT, TraitT > | |
const value_type & | data () const |
Returns the value of the data buffer. | |
void | data (const value_type &value) |
Returns the value of the data buffer. | |
value_type & | reference () |
Returns a reference to the internal data storage. More... | |
Additional Inherited Members | |
Public Types inherited from Hg::Datum< kt_idx, format_t > | |
typedef detail::DefineFieldType< Idx, format_t >::type | field_type |
Type mapping for the message format type to the actual value_type. | |
typedef format_t | format_type |
format of the parent TypeList. | |
typedef field_type::index_type | index_type |
The type extracted at the current index defined in the parent TypeList. | |
typedef field_type::value_type | value_type |
The data type managed by this Datum. This is the type of data that will be written to the attached buffer. | |
Static Public Attributes inherited from Hg::Datum< kt_idx, format_t > | |
static const size_t | k_offset |
The offset in the buffer where this msg field is located. | |
Protected Member Functions inherited from Hg::Datum< kt_idx, format_t > | |
const value_type & | get_data () const |
Returns the value of the data buffer. | |
value_type & | get_reference () |
Returns a reference to the internal data storage. More... | |
void | set_data (const value_type &value) |
Returns the value of the data buffer. | |
Protected Attributes inherited from Hg::detail::FieldTypes< FieldT, TraitT > | |
value_type | m_data |
This is a local copy of the data value to shadow the value held in the buffer. | |
A template to adapt all field types to the Datum assignment.
datum_trait The general category of proxy management required by the specified field. kt_idx format_type kt_offset
Definition at line 42 of file data_proxy.h.
|
inline |
Copy Constructor.
Makes a complete copy of an existing Proxy object.
proxy | A reference to the Another instance of a DataProxy. |
Definition at line 68 of file data_proxy.h.
|
inline |
Value Constructor: Construct a proxy directly from a datum instance.
datum | A reference to a datum object used to initilize this. |
Definition at line 78 of file data_proxy.h.
|
inline |
Conversion operator to a base Datum Type reference.
Definition at line 135 of file data_proxy.h.
|
inline |
Value Conversion Operator (value_type)
Allows the entire Object-type to be extracted and assigned as a value to the host value type.
Definition at line 146 of file data_proxy.h.