You.i Engine
YiIntegralConstant< Type, templateValue > Struct Template Reference

Detailed Description

template<typename Type, Type templateValue>
struct YiIntegralConstant< Type, templateValue >

A backported equivalent of std::integral_constant, making the feature available on platforms that don't implement it.

See http://en.cppreference.com/w/cpp/types/integral_constant for more details.

Note that all members and variable match the STL equivalent names for consistency.

#include <utility/YiTypeTraits.h>

Public Types

typedef Type value_type
 
typedef YiIntegralConstant< Type, templateValue > type
 

Public Member Functions

 operator value_type () const
 
value_type operator() () const
 

Static Public Attributes

static const Type value = templateValue
 

Member Typedef Documentation

◆ type

template<typename Type , Type templateValue>
typedef YiIntegralConstant<Type, templateValue> YiIntegralConstant< Type, templateValue >::type

◆ value_type

template<typename Type , Type templateValue>
typedef Type YiIntegralConstant< Type, templateValue >::value_type

Member Function Documentation

◆ operator value_type()

template<typename Type , Type templateValue>
YiIntegralConstant< Type, templateValue >::operator value_type ( ) const
inline

Conversion function which returns the wrapped value.

◆ operator()()

template<typename Type , Type templateValue>
value_type YiIntegralConstant< Type, templateValue >::operator() ( ) const
inline

Returns the wrapped value.

This function enables YiIntegralConstant to serve as a source of compile-time function objects.

Member Data Documentation

◆ value

template<typename Type , Type templateValue>
const Type YiIntegralConstant< Type, templateValue >::value = templateValue
static

Static constant of type 'Type' with value 'templateValue'.


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