Main Page | Modules | Namespace List | Class Hierarchy | Class List | Namespace Members | Class Members

Triple< T1, T2, T3 > Class Template Reference
[Miscellaneous]

Triple Class. More...

#include <triple.h>

List of all members.

Public Member Functions

virtual void clear () throw ()
 Clear method.
Constructors and Destructors
 Triple () throw ()
 Default constructor.
 Triple (const Triple &triple, bool deep=true) throw ()
 Copy constructor.
 Triple (const T1 &new_first, const T2 &new_second, const T3 &new_third) throw ()
 Detailed constructor.
virtual ~Triple () throw ()
 Destructor.
Assignment
const Tripleoperator= (const Triple &triple) throw ()
 Assignment operator.
void set (const T1 &t1, const T2 &t2, const T3 &t3) throw ()
void get (T1 &first, T2 &second, T3 &third) const throw ()
Predicates
bool operator== (const Triple &triple) const throw ()
 Equality operator Two instances are equal if they have the same members.
bool operator!= (const Triple &triple) const throw ()
 Inequality operator.
bool operator< (const Triple &triple) const throw ()
 Lesser than operator.
bool operator<= (const Triple &triple) const throw ()
 Lesser or equal than operator.
bool operator>= (const Triple &triple) const throw ()
 Greater or equal than operator.
bool operator> (const Triple &triple) const throw ()
 Greater than operator.

Public Attributes

Attributes
T1 first
 The first triple member.
T2 second
 The second triple member.
T3 third
 The third triple member.


Detailed Description

template<typename T1, typename T2, typename T3>
class Triple< T1, T2, T3 >

Triple Class.

This template class is used to represent triples of arbitrary types (like the STL type pair).

See also:
Quadruple


Constructor & Destructor Documentation

template<typename T1, typename T2, typename T3>
Triple< T1, T2, T3 >::Triple  )  throw ()
 

Default constructor.

Creates a new Triple object.

template<typename T1, typename T2, typename T3>
Triple< T1, T2, T3 >::Triple const Triple< T1, T2, T3 > &  triple,
bool  deep = true
throw ()
 

Copy constructor.

Creates a new Triple object from another.

Parameters:
triple the Triple object to be copied
deep not used (needed for a consistent interface only)

template<typename T1, typename T2, typename T3>
Triple< T1, T2, T3 >::Triple const T1 &  new_first,
const T2 &  new_second,
const T3 &  new_third
throw ()
 

Detailed constructor.

Creates a new Triple object from the triple's three members.

Parameters:
new_first the first triple member
new_second the second triple member
new_third the third triple member

template<typename T1, typename T2, typename T3>
Triple< T1, T2, T3 >::~Triple  )  throw () [virtual]
 

Destructor.

Destructs the Triple object.


Member Function Documentation

template<typename T1, typename T2, typename T3>
void Triple< T1, T2, T3 >::clear  )  throw () [virtual]
 

Clear method.

template<typename T1, typename T2, typename T3>
bool Triple< T1, T2, T3 >::operator< const Triple< T1, T2, T3 > &  triple  )  const throw ()
 

Lesser than operator.

One instance is lesser than an other if all members from first to third are equal or less than the members of the other instance and at least threeth is less.

template<typename T1, typename T2, typename T3>
bool Triple< T1, T2, T3 >::operator<= const Triple< T1, T2, T3 > &  triple  )  const throw ()
 

Lesser or equal than operator.

template<typename T1, typename T2, typename T3>
const Triple< T1, T2, T3 > & Triple< T1, T2, T3 >::operator= const Triple< T1, T2, T3 > &  triple  )  throw ()
 

Assignment operator.

Assigns the contents of a triple to another.

Parameters:
triple the triple to be copied

template<typename T1, typename T2, typename T3>
bool Triple< T1, T2, T3 >::operator== const Triple< T1, T2, T3 > &  triple  )  const throw ()
 

Equality operator Two instances are equal if they have the same members.

template<typename T1, typename T2, typename T3>
bool Triple< T1, T2, T3 >::operator> const Triple< T1, T2, T3 > &  triple  )  const throw ()
 

Greater than operator.

template<typename T1, typename T2, typename T3>
bool Triple< T1, T2, T3 >::operator>= const Triple< T1, T2, T3 > &  triple  )  const throw ()
 

Greater or equal than operator.