dlr::common::Triple< Type0, Type1, Type2 > Class Template Reference

The Triple class provides a convenient way to pass groups of three things around. More...

#include <triple.h>

List of all members.

Public Types

typedef Type0 first_type
 This describes the type of the first element of the triple.
typedef Type1 second_type
 This describes the type of the second element of the triple.
typedef Type2 third_type
 This describes the type of the Third element of the triple.

Public Member Functions

 Triple ()
 Default constructor initializes all members to default values.
 Triple (const Type0 &element0, const Type1 &element1, const Type2 &element2)
 This constructor copies each of its arguments into the triple.
template<class OtherType0 , class OtherType1 , class OtherType2 >
 Triple (const Triple< OtherType0, OtherType1, OtherType2 > &other)
 This constructor copies each element of another triple.
 ~Triple ()
 Empty destructor.

Public Attributes

Type0 first
 This public data member holds the first element of the triple.
Type1 second
 This public data member holds the second element of the triple.
Type2 third
 This public data member holds the third element of the triple.


Detailed Description

template<class Type0, class Type1, class Type2>
class dlr::common::Triple< Type0, Type1, Type2 >

The Triple class provides a convenient way to pass groups of three things around.

It's intended to be just like std::pair, but with three elements. It is based on Stroustrup's implementation of class pair, taken from "The C++ Programming Language," 3rd Edition, Addison Wesley, 1997-2000.

Definition at line 30 of file triple.h.


Member Typedef Documentation

template<class Type0, class Type1, class Type2>
typedef Type0 dlr::common::Triple< Type0, Type1, Type2 >::first_type

This describes the type of the first element of the triple.

Definition at line 36 of file triple.h.

template<class Type0, class Type1, class Type2>
typedef Type1 dlr::common::Triple< Type0, Type1, Type2 >::second_type

This describes the type of the second element of the triple.

Definition at line 39 of file triple.h.

template<class Type0, class Type1, class Type2>
typedef Type2 dlr::common::Triple< Type0, Type1, Type2 >::third_type

This describes the type of the Third element of the triple.

Definition at line 42 of file triple.h.


Constructor & Destructor Documentation

template<class Type0, class Type1, class Type2>
dlr::common::Triple< Type0, Type1, Type2 >::Triple (  )  [inline]

Default constructor initializes all members to default values.

Definition at line 48 of file triple.h.

template<class Type0, class Type1, class Type2>
dlr::common::Triple< Type0, Type1, Type2 >::Triple ( const Type0 &  element0,
const Type1 &  element1,
const Type2 &  element2 
) [inline]

This constructor copies each of its arguments into the triple.

Parameters:
element0 This argument will be copied to the first element of the new Triple.
element1 This argument will be copied to the first element of the new Triple.
element2 This argument will be copied to the first element of the new Triple.

Definition at line 60 of file triple.h.

template<class Type0, class Type1, class Type2>
template<class OtherType0 , class OtherType1 , class OtherType2 >
dlr::common::Triple< Type0, Type1, Type2 >::Triple ( const Triple< OtherType0, OtherType1, OtherType2 > &  other  )  [inline]

This constructor copies each element of another triple.

Note that the types of the elements of the copied triple will be explicitly cast to types of the elements of the the constructed triple.

Parameters:
source This argument is the triple to be copied.

Definition at line 72 of file triple.h.

template<class Type0, class Type1, class Type2>
dlr::common::Triple< Type0, Type1, Type2 >::~Triple (  )  [inline]

Empty destructor.

Definition at line 80 of file triple.h.


Member Data Documentation

template<class Type0, class Type1, class Type2>
Type0 dlr::common::Triple< Type0, Type1, Type2 >::first

This public data member holds the first element of the triple.

Definition at line 87 of file triple.h.

template<class Type0, class Type1, class Type2>
Type1 dlr::common::Triple< Type0, Type1, Type2 >::second

This public data member holds the second element of the triple.

Definition at line 92 of file triple.h.

template<class Type0, class Type1, class Type2>
Type2 dlr::common::Triple< Type0, Type1, Type2 >::third

This public data member holds the third element of the triple.

Definition at line 97 of file triple.h.


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

Generated on Tue Nov 24 23:57:57 2009 for dlrCommon Utility Library by  doxygen 1.5.8