Dune::tuple< T1, T2, T3, T4, T5, T6, T7, T8, T9 > Class Template Reference
[Common]

#include <tuples.hh>

Inheritance diagram for Dune::tuple< T1, T2, T3, T4, T5, T6, T7, T8, T9 >:

Dune::Pair< T1, TT >

List of all members.


Detailed Description

template<typename T1, typename T2 = Nil, typename T3 = Nil, typename T4 = Nil, typename T5 = Nil, typename T6 = Nil, typename T7 = Nil, typename T8 = Nil, typename T9 = Nil>
class Dune::tuple< T1, T2, T3, T4, T5, T6, T7, T8, T9 >

A Tuple of objects.

A maximum of 9 objects is supported.

Use the following construction to access the individual elements.

      tuple<std::string, float*, int> my_tuple;

      std:string& s = get<0>(my_tuple);
      float*      p = get<1>(my_tuple);

      // Access the third element in a generic way
      typedef tuple_element<2, tuple<std::string, float*, int> >::type Type;
      Type&       i = get<2>(my_tuple);

Public Types

typedef TupleToPairs< T1, T2,
T3, T4, T5, T6, T7, T8, T9 >
::Type 
FirstPair
 Type of the first Pair defining the Tuple.
typedef T1 Type1
 The type of the first field.
typedef TT Type2
 The type of the second field.

Public Member Functions

template<class U1, class U2>
tupleoperator= (const Pair< U1, U2 > &other)
 Assignment operator for implicit type conversion.
TupleAccessTraits< Type1 >
::NonConstType 
first ()
 Get the first value.
TupleAccessTraits< Type1 >
::ConstType 
first () const
 Get the first value.
TupleAccessTraits< Type2 >
::NonConstType 
second ()
 Get the second value.
TupleAccessTraits< Type2 >
::ConstType 
second () const
 Get the second value.

Public Attributes

Type1 first_
 The value of the first field.
Type2 second_
 The value of the second field.

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

Generated on Tue Jul 28 22:28:00 2009 for dune-common by  doxygen 1.5.6