TPIE

2362a60
tpie::op2TPIE_cmp< T > Class Template Reference

Convert a class with a comparison operator < to a TPIE comparison object with a compare() function. More...

#include <tpie/comparator.h>

Public Member Functions

int compare (const T &left, const T &right)
 Do not use with applications that test if compare returns +1 Because it never does so. More...
 

Detailed Description

template<class T>
class tpie::op2TPIE_cmp< T >

Convert a class with a comparison operator < to a TPIE comparison object with a compare() function.

Definition at line 95 of file comparator.h.

Member Function Documentation

template<class T >
int tpie::op2TPIE_cmp< T >::compare ( const T &  left,
const T &  right 
)
inline

Do not use with applications that test if compare returns +1 Because it never does so.

Definition at line 105 of file comparator.h.

105  {
106  if( left < right ){ return -1; }
107  else { return 0; }
108  }

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