CppNoddy
0.92
|
A function object predicate that first computes the absolute difference between two elements and a specified value, then compares these two resulting values. More...
#include <Functors.h>
Public Member Functions | |
absDiff_predicate (_Type value) | |
bool | operator() (_Type elt1, _Type elt2) |
Returns true of the first argument is closer to the specified (in constructor) value than the second argument. More... | |
A function object predicate that first computes the absolute difference between two elements and a specified value, then compares these two resulting values.
Used for computing which of two components is nearest to the specified value.
Definition at line 30 of file Functors.h.
|
inline |
value | The target value that is to used. |
Definition at line 33 of file Functors.h.
|
inline |
Returns true of the first argument is closer to the specified (in constructor) value than the second argument.
elt1 | The first value to be used in the comparison |
elt2 | The second value to be used in the comparison |
Definition at line 41 of file Functors.h.
© 2012
R.E. Hewitt