lite::get_type< index_, type_ > Struct Template Reference
[Tool Classes]

This class can be used to retrieve the type of the elements of a pack type. More...

#include <array.hpp>

List of all members.

Public Attributes

typedef type
 This is the same type as type_::typeX assuming that X is the index_ .

Detailed Description

template<int index_, typename type_>
struct lite::get_type< index_, type_ >

This class can be used to retrieve the type of the elements of a pack type.

This is useful if the index of the element is computed as the result of a compile time expression.

Example:
        typedef pack<int, constant<int, 5>, std::string> Pack;

        Pack p(1, 0, "hello");
        get_type<1, Pack>::type& ref = p.i1;
        std::cout << ref << std::endl;

The output would be:

        5
    

The documentation for this struct was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Defines

Generated on Fri Nov 6 02:03:21 2009 for Lite by  doxygen 1.6.0