Sierra Toolkit  Version of the Day
functional_rdestl.h
1 #ifndef RDESTL_FUNCTIONAL_H
2 #define RDESTL_FUNCTIONAL_H
3 
4 namespace rde
5 {
6 //=============================================================================
7 template<typename T>
8 struct less
9 {
10  bool operator()(const T& lhs, const T& rhs) const
11  {
12  return lhs < rhs;
13  }
14 };
15 
16 //=============================================================================
17 template<typename T>
18 struct greater
19 {
20  bool operator()(const T& lhs, const T& rhs) const
21  {
22  return lhs > rhs;
23  }
24 };
25 
26 //=============================================================================
27 template<typename T>
28 struct equal_to
29 {
30  bool operator()(const T& lhs, const T& rhs) const
31  {
32  return lhs == rhs;
33  }
34 };
35 
36 }
37 
38 //-----------------------------------------------------------------------------
39 #endif // #ifndef RDESTL_FUNCTIONAL_H