48#ifndef GUM_THREAD_DATA_H
49#define GUM_THREAD_DATA_H
74 template <
typename T_DATA >
79 using data_type = std::conditional< std::is_scalar< T_DATA >::value, T_DATA, T_DATA& >;
139 typename std::conditional< std::is_pointer< T_DATA >::value,
141 typename std::add_pointer< T_DATA >::type >::type;
143 template <
typename X = T_DATA >
146 template <
typename X = T_DATA >
gum is the global namespace for all aGrUM entities
bool operator!=(const ThreadData< T_DATA > &from) const
inequality operator
ThreadData(const T_DATA &theData)
default constructor
typename std::conditional< std::is_pointer< T_DATA >::value, T_DATA, typename std::add_pointer< T_DATA >::type >::type data_pointer
the data we wish to store without cacheline parallel problem
std::conditional< std::is_scalar< T_DATA >::value, T_DATA, T_DATA & > data_type
the return types of accessors: T_DATA if scalar, else T_DATA&
std::enable_if_t< std::is_pointer< X >::value, data_pointer > operator->()
the data we wish to store without cacheline parallel problem
ThreadData< T_DATA > & operator=(const ThreadData< T_DATA > &from)
copy operator
bool operator==(const ThreadData< T_DATA > &from) const
equality operator
T_DATA data
the data we wish to store without cacheline parallel problem
~ThreadData()=default
destructor
data_type operator*()
easy accessor
std::enable_if_t< !std::is_pointer< X >::value, data_pointer > operator->()
the data we wish to store without cacheline parallel problem