All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Types | Public Member Functions | Public Attributes | List of all members
cluster::details::MultiValue Class Reference

Class holding a value of one among some selected types... More...

#include <OverriddenClusterParamsAlg.h>

Public Types

using Measure_t = cluster::details::Measure_t< float >
 

Public Member Functions

 MultiValue ()
 
template<typename T >
MultiValueoperator= (T)
 Sets the value from a value of type T; undefined by default. More...
 
template<typename T >
 operator T () const
 Converts the value to type T; undefined by default. More...
 
template<>
MultiValueoperator= (size_t value)
 
template<>
MultiValueoperator= (float value)
 
template<>
MultiValueoperator= (Measure_t value)
 

Public Attributes

union {
   Measure_t   measure_value
 
   float   float_value
 
   size_t   size_t_value
 
}; 
 

Detailed Description

Class holding a value of one among some selected types...

FIXME: If this functionality is necessary, it should be replaced with std::variant.

Definition at line 30 of file OverriddenClusterParamsAlg.h.

Member Typedef Documentation

Definition at line 32 of file OverriddenClusterParamsAlg.h.

Constructor & Destructor Documentation

cluster::details::MultiValue::MultiValue ( )
inline

Default constructor; it's here only to allow for vectors to be resized and its effect is undefined. This class is not to be considered valid until it's assigned a value with the operator= .

Definition at line 43 of file OverriddenClusterParamsAlg.h.

43 {}

Member Function Documentation

template<typename T >
cluster::details::MultiValue::operator T ( ) const

Converts the value to type T; undefined by default.

template<typename T >
MultiValue& cluster::details::MultiValue::operator= ( )

Sets the value from a value of type T; undefined by default.

template<>
MultiValue& cluster::details::MultiValue::operator= ( size_t  value)

Definition at line 372 of file OverriddenClusterParamsAlg.h.

373  {
375  return *this;
376  }
temporary value
template<>
MultiValue& cluster::details::MultiValue::operator= ( float  value)

Definition at line 387 of file OverriddenClusterParamsAlg.h.

388  {
389  float_value = value;
390  return *this;
391  }
temporary value
template<>
MultiValue& cluster::details::MultiValue::operator= ( Measure_t  value)

Definition at line 402 of file OverriddenClusterParamsAlg.h.

403  {
405  return *this;
406  }
temporary value

Member Data Documentation

union { ... }
float cluster::details::MultiValue::float_value

Definition at line 36 of file OverriddenClusterParamsAlg.h.

Measure_t cluster::details::MultiValue::measure_value

Definition at line 35 of file OverriddenClusterParamsAlg.h.

size_t cluster::details::MultiValue::size_t_value

Definition at line 37 of file OverriddenClusterParamsAlg.h.


The documentation for this class was generated from the following file: