#include <comparator.h>
Public Member Functions |
|
Constructors and Destructors
|
|
Comparator () | |
Default constructor. |
|
virtual | ~Comparator () |
Destructor. |
|
Predicates
|
|
virtual bool | isEqual (const T &a, const T &b) const |
Test if two values are
equal. |
|
bool | isNotEqual (const T &a, const T &b) const |
Test if two values are
unequal. |
|
virtual bool | isLess (const T &a, const T &b) const |
Test if a is less then b. |
|
bool | isLessOrEqual (const T &a, const T &b) const |
Test if a is less or
equal. |
|
bool | isGreaterOrEqual (const T &a, const T &b) const |
Test if a is greater or
equal. |
|
bool | isGreater (const T &a, const T &b) const |
Test if a is greater then
b. |
|
int | operator() (const T &a, const T &b) const |
Compare two values. |
It is used as a baseclass, providing a common interface.
int BALL::Comparator< T >::operator() | ( | const T & | a, | |
const T & | b | |||
) | const |
Compare two values.
-1 is returned if a < b.
References BALL::Comparator< T >::isEqual(), and BALL::Comparator< T >::isLess().