max.h 1.36 KB
Newer Older
thomas.forbriger's avatar
thomas.forbriger committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
/*! \file max.h
 * \brief return maximum element value (prototypes)
 * 
 * ----------------------------------------------------------------------------
 * 
 * $Id: max.h,v 1.1 2005-03-21 09:35:33 tforb Exp $
 * \author Thomas Forbriger
 * \date 20/03/2005
 * 
 * return maximum element value (prototypes)
 * 
 * Copyright (c) 2005 by Thomas Forbriger (BFO Schiltach) 
 * 
 * REVISIONS and CHANGES 
 *  - 20/03/2005   V1.0   Thomas Forbriger
 * 
 * ============================================================================
 */

// include guard
#ifndef AFF_MAX_H_VERSION

#define AFF_MAX_H_VERSION \
  "AFF_MAX_H   V1.0   "
#define AFF_MAX_H_CVSID \
  "$Id: max.h,v 1.1 2005-03-21 09:35:33 tforb Exp $"

#include<aff/lib/collector.h>

namespace aff {

  namespace func {

    namespace util {

      template<class T>
        class MaxCollector { 
          public:
            typedef T Tvalue;
            MaxCollector(): Mval(Tvalue()) { }
            MaxCollector(const Tvalue& v): Mval(v) { }
            MaxCollector operator() (cont Tvalue& v)
            { 
              Mval
          private:
            T Mval;
        }; // class MaxCollector

    } // namespace util

    template<class C, class T>
      T max(const typename C<T>::Tcoc& c)
      {
      }

  } // namespace func

} // namespace aff

#endif // AFF_MAX_H_VERSION (includeguard)

/* ----- END OF max.h ----- */