Ion
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
ion::math::Range1TWrapper< T, N > Struct Template Reference

This struct allows the Endpoint and Size types in a Range<1, T> to be treated like those of higher-dimension Range classes (specifically the use of index operators) to simplify templated functions that use them. More...

#include "range.h"

Collaboration diagram for ion::math::Range1TWrapper< T, N >:

Public Member Functions

 Range1TWrapper ()
 
 Range1TWrapper (const T &t_in)
 
 operator T () const
 
Toperator[] (int index)
 
const Toperator[] (int index) const
 

Static Public Member Functions

static const T Zero ()
 

Public Attributes

T t
 

Friends

template<typename U >
std::istream & operator>> (std::istream &in, Range1TWrapper< U, 0 > &w)
 Allows reading wrapped value from a stream. More...
 

Detailed Description

template<typename T, int N>
struct ion::math::Range1TWrapper< T, N >

This struct allows the Endpoint and Size types in a Range<1, T> to be treated like those of higher-dimension Range classes (specifically the use of index operators) to simplify templated functions that use them.

It is essentially an implicit wrapper around a value of type T.

Definition at line 38 of file range.h.

Constructor & Destructor Documentation

template<typename T, int N>
ion::math::Range1TWrapper< T, N >::Range1TWrapper ( )
inline

Definition at line 39 of file range.h.

template<typename T, int N>
ion::math::Range1TWrapper< T, N >::Range1TWrapper ( const T t_in)
inline

Definition at line 40 of file range.h.

Member Function Documentation

template<typename T, int N>
ion::math::Range1TWrapper< T, N >::operator T ( ) const
inline

Definition at line 41 of file range.h.

References ion::math::Range1TWrapper< T, N >::t.

template<typename T, int N>
T& ion::math::Range1TWrapper< T, N >::operator[] ( int  index)
inline

Definition at line 42 of file range.h.

References DCHECK_EQ, and ion::math::Range1TWrapper< T, N >::t.

template<typename T, int N>
const T& ion::math::Range1TWrapper< T, N >::operator[] ( int  index) const
inline

Definition at line 46 of file range.h.

References DCHECK_EQ, and ion::math::Range1TWrapper< T, N >::t.

template<typename T, int N>
static const T ion::math::Range1TWrapper< T, N >::Zero ( )
inlinestatic

Definition at line 51 of file range.h.

Friends And Related Function Documentation

template<typename T, int N>
template<typename U >
std::istream& operator>> ( std::istream &  in,
Range1TWrapper< U, 0 > &  w 
)
friend

Allows reading wrapped value from a stream.

Member Data Documentation


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