Array variant type. More...
#include <ArrayVariant.h>
Classes | |
class | Value |
Array variant value (abstract base) More... | |
class | ValueImplT |
Array variant value (templated implementation) More... | |
class | ValueImplV |
Array variant value (variant-typed implementation) More... | |
Public Member Functions | |
void | addMember (const Variant &member) |
Add a member to the array. | |
ArrayVariant () | |
Default constructor. | |
ArrayVariant (const ArrayVariant &src) | |
Copy constructor. | |
ArrayVariant (const Variant &src) | |
Copy constructor (overloaded version taking a variant) | |
void | clear () |
Clear the array. | |
ArrayVariant & | operator+= (const Variant &member) |
Operator for adding a member to the array. | |
void | resize (size_t numMembers) |
Resize the array. | |
~ArrayVariant () | |
Destructor. | |
Protected Member Functions | |
ArrayVariant (const DataType &type, const DataType &memberType, size_t numMembers) | |
Constructor (overloaded version taking an array data type and a size) | |
Static Protected Member Functions | |
template<typename T > | |
static void | add (typename type_traits::ArrayType< T >::ValueType &array, const typename type_traits::ArrayType< T >::MemberType &member, typename boost::enable_if< typename type_traits::ArrayType< T >::IsDynamic >::type *=0) |
Add a member to an array (overloaded version taking a dynamic array) | |
template<typename T > | |
static void | add (typename type_traits::ArrayType< T >::ValueType &array, const typename type_traits::ArrayType< T >::MemberType &member, typename boost::disable_if< typename type_traits::ArrayType< T >::IsDynamic >::type *=0) |
Add a member to an array (overloaded version taking a non-dynamic array) | |
template<typename T > | |
static void | clear (typename type_traits::ArrayType< T >::ValueType &array, typename boost::enable_if< typename type_traits::ArrayType< T >::IsDynamic >::type *=0) |
Clear an array (overloaded version taking a dynamic array) | |
template<typename T > | |
static void | clear (typename type_traits::ArrayType< T >::ValueType &array, typename boost::disable_if< typename type_traits::ArrayType< T >::IsDynamic >::type *=0) |
Clear an array (overloaded version taking a non-dynamic array) | |
template<typename T > | |
static ArrayVariant | create (const DataType &type, const DataType &memberType) |
Create an array variant. | |
template<typename T > | |
static void | initialize (typename type_traits::ArrayType< T >::ValueType &array, typename boost::enable_if< typename type_traits::ArrayType< T >::IsDynamic >::type *=0) |
Initialize an array (overloaded version taking a dynamic array) | |
template<typename T > | |
static void | initialize (typename type_traits::ArrayType< T >::ValueType &array, typename boost::disable_if< typename type_traits::ArrayType< T >::IsDynamic >::type *=0) |
Initialize an array (overloaded version taking a non-dynamic array) | |
template<typename T > | |
static void | resize (typename type_traits::ArrayType< T >::ValueType &array, size_t numMembers, typename boost::enable_if< typename type_traits::ArrayType< T >::IsDynamic >::type *=0) |
Resize an array (overloaded version taking a dynamic array) | |
template<typename T > | |
static void | resize (typename type_traits::ArrayType< T >::ValueType &array, size_t numMembers, typename boost::disable_if< typename type_traits::ArrayType< T >::IsDynamic >::type *=0) |
Resize an array (overloaded version taking a non-dynamic array) | |
Friends | |
class | ArrayDataType |
class | Variant |
Array variant type.
Definition at line 34 of file ArrayVariant.h.
Default constructor.
Definition at line 30 of file ArrayVariant.cpp.
variant_topic_tools::ArrayVariant::ArrayVariant | ( | const ArrayVariant & | src | ) |
Copy constructor.
Definition at line 40 of file ArrayVariant.cpp.
variant_topic_tools::ArrayVariant::ArrayVariant | ( | const Variant & | src | ) |
Copy constructor (overloaded version taking a variant)
Definition at line 44 of file ArrayVariant.cpp.
Destructor.
Definition at line 50 of file ArrayVariant.cpp.
variant_topic_tools::ArrayVariant::ArrayVariant | ( | const DataType & | type, |
const DataType & | memberType, | ||
size_t | numMembers | ||
) | [protected] |
Constructor (overloaded version taking an array data type and a size)
Definition at line 33 of file ArrayVariant.cpp.
static void variant_topic_tools::ArrayVariant::add | ( | typename type_traits::ArrayType< T >::ValueType & | array, |
const typename type_traits::ArrayType< T >::MemberType & | member, | ||
typename boost::enable_if< typename type_traits::ArrayType< T >::IsDynamic >::type * | = 0 |
||
) | [static, protected] |
Add a member to an array (overloaded version taking a dynamic array)
static void variant_topic_tools::ArrayVariant::add | ( | typename type_traits::ArrayType< T >::ValueType & | array, |
const typename type_traits::ArrayType< T >::MemberType & | member, | ||
typename boost::disable_if< typename type_traits::ArrayType< T >::IsDynamic >::type * | = 0 |
||
) | [static, protected] |
Add a member to an array (overloaded version taking a non-dynamic array)
void variant_topic_tools::ArrayVariant::addMember | ( | const Variant & | member | ) |
Add a member to the array.
Definition at line 154 of file ArrayVariant.cpp.
Clear the array.
Reimplemented from variant_topic_tools::Variant.
Definition at line 172 of file ArrayVariant.cpp.
static void variant_topic_tools::ArrayVariant::clear | ( | typename type_traits::ArrayType< T >::ValueType & | array, |
typename boost::enable_if< typename type_traits::ArrayType< T >::IsDynamic >::type * | = 0 |
||
) | [static, protected] |
Clear an array (overloaded version taking a dynamic array)
static void variant_topic_tools::ArrayVariant::clear | ( | typename type_traits::ArrayType< T >::ValueType & | array, |
typename boost::disable_if< typename type_traits::ArrayType< T >::IsDynamic >::type * | = 0 |
||
) | [static, protected] |
Clear an array (overloaded version taking a non-dynamic array)
static ArrayVariant variant_topic_tools::ArrayVariant::create | ( | const DataType & | type, |
const DataType & | memberType | ||
) | [static, protected] |
Create an array variant.
static void variant_topic_tools::ArrayVariant::initialize | ( | typename type_traits::ArrayType< T >::ValueType & | array, |
typename boost::enable_if< typename type_traits::ArrayType< T >::IsDynamic >::type * | = 0 |
||
) | [static, protected] |
Initialize an array (overloaded version taking a dynamic array)
static void variant_topic_tools::ArrayVariant::initialize | ( | typename type_traits::ArrayType< T >::ValueType & | array, |
typename boost::disable_if< typename type_traits::ArrayType< T >::IsDynamic >::type * | = 0 |
||
) | [static, protected] |
Initialize an array (overloaded version taking a non-dynamic array)
ArrayVariant & variant_topic_tools::ArrayVariant::operator+= | ( | const Variant & | member | ) |
Operator for adding a member to the array.
Definition at line 245 of file ArrayVariant.cpp.
void variant_topic_tools::ArrayVariant::resize | ( | size_t | numMembers | ) |
Resize the array.
Definition at line 165 of file ArrayVariant.cpp.
static void variant_topic_tools::ArrayVariant::resize | ( | typename type_traits::ArrayType< T >::ValueType & | array, |
size_t | numMembers, | ||
typename boost::enable_if< typename type_traits::ArrayType< T >::IsDynamic >::type * | = 0 |
||
) | [static, protected] |
Resize an array (overloaded version taking a dynamic array)
static void variant_topic_tools::ArrayVariant::resize | ( | typename type_traits::ArrayType< T >::ValueType & | array, |
size_t | numMembers, | ||
typename boost::disable_if< typename type_traits::ArrayType< T >::IsDynamic >::type * | = 0 |
||
) | [static, protected] |
Resize an array (overloaded version taking a non-dynamic array)
friend class ArrayDataType [friend] |
Definition at line 36 of file ArrayVariant.h.
friend class Variant [friend] |
Reimplemented from variant_topic_tools::CollectionVariant.
Definition at line 37 of file ArrayVariant.h.