Galois::LazyObject< T > Class Template Reference

Single (uninitialized) object with specialization for void type. More...

#include <LazyObject.h>

List of all members.

Classes

union  Data
struct  size_of

Public Types

typedef T value_type
typedef T & reference
typedef const T & const_reference

Public Member Functions

void destroy ()
void construct (const_reference x)
template<typename... Args>
void construct (Args &&...args)
const_reference get () const
reference get ()

Static Public Attributes

static const bool has_value = true

Private Types

typedef std::aligned_storage
< sizeof(T), std::alignment_of
< T >::value >::type 
CharData

Private Member Functions

T * cast ()
const T * cast () const

Private Attributes

Data data_

Detailed Description

template<typename T>
class Galois::LazyObject< T >

Single (uninitialized) object with specialization for void type.

To take advantage of empty member optimization, users should subclass this class, otherwise the compiler will insert non-zero padding for fields (even when empty).


Member Typedef Documentation

template<typename T>
typedef std::aligned_storage<sizeof(T), std::alignment_of<T>::value>::type Galois::LazyObject< T >::CharData [private]
template<typename T>
typedef const T& Galois::LazyObject< T >::const_reference
template<typename T>
typedef T& Galois::LazyObject< T >::reference
template<typename T>
typedef T Galois::LazyObject< T >::value_type

Member Function Documentation

template<typename T>
const T* Galois::LazyObject< T >::cast (  )  const [inline, private]
template<typename T>
T* Galois::LazyObject< T >::cast (  )  [inline, private]
template<typename T>
template<typename... Args>
void Galois::LazyObject< T >::construct ( Args &&...  args  )  [inline]
template<typename T>
void Galois::LazyObject< T >::construct ( const_reference  x  )  [inline]
template<typename T>
void Galois::LazyObject< T >::destroy (  )  [inline]
template<typename T>
reference Galois::LazyObject< T >::get (  )  [inline]
template<typename T>
const_reference Galois::LazyObject< T >::get (  )  const [inline]

Member Data Documentation

template<typename T>
Data Galois::LazyObject< T >::data_ [private]
template<typename T>
const bool Galois::LazyObject< T >::has_value = true [static]

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

Generated on 2 Nov 2013 for Galois by  doxygen 1.6.1