Jpp
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
JGridMap.hh
Go to the documentation of this file.
1 #ifndef __JTOOLS__JGRIDMAP__
2 #define __JTOOLS__JGRIDMAP__
3 
6 
7 
8 /**
9  * \author mdejong
10  */
11 
12 namespace JTOOLS {}
13 namespace JPP { using namespace JTOOLS; }
14 
15 namespace JTOOLS {
16 
17 
18  /**
19  * Map of equidistant pair-wise elements.
20  *
21  * The key_type and mapped_type refer to the pair-wise element of this map, respectively.
22  */
23  template<class JKey_t,
24  class JValue_t,
25  class JDistance_t = JDistance<JKey_t> >
26  class JGridMap :
27  public JGridCollection<JElement2D<JKey_t, JValue_t>, JDistance_t>
28  {
29  public:
30 
31  typedef JKey_t key_type;
32  typedef JValue_t mapped_type;
33 
35 
39 
44 
45 
46  /**
47  * Default constructor.
48  */
50  {}
51  };
52 
53 
54  /**
55  * Specialisation of JMapCollection for JGridMap.
56  */
57  template<>
59  /**
60  * Collection of elements.
61  */
62  template<class JElement_t,
64  struct collection_type :
65  public JGridCollection<JElement_t, JDistance_t>
66  {};
67  };
68 }
69 
70 #endif
JKey_t key_type
Definition: JGridMap.hh:31
collection_type::value_type value_type
Definition: JGridMap.hh:38
JGridMap()
Default constructor.
Definition: JGridMap.hh:49
General purpose class for collection of elements, see: &lt;a href=&quot;JTools.PDF&quot;;&gt;Collection of elements...
Definition: JCollection.hh:73
JGridCollection< JElement2D< JKey_t, JValue_t >, JDistance_t > collection_type
Definition: JGridMap.hh:34
collection_type::reverse_iterator reverse_iterator
Definition: JGridMap.hh:43
Template class for distance evaluation.
Definition: JDistance.hh:24
JElement2D< JKey_t, JHistogram_t >::abscissa_type abscissa_type
Definition: JCollection.hh:82
collection_type::iterator iterator
Definition: JGridMap.hh:42
General purpose class for collection of equidistant elements.
collection_type::ordinate_type ordinate_type
Definition: JGridMap.hh:37
Template class to define the corresponding JCollection for a given template JMap. ...
JElement2D< JKey_t, JHistogram_t >::ordinate_type ordinate_type
Definition: JCollection.hh:83
Map of equidistant pair-wise elements.
Definition: JGridMap.hh:26
collection_type::const_iterator const_iterator
Definition: JGridMap.hh:40
collection_type::abscissa_type abscissa_type
Definition: JGridMap.hh:36
2D Element.
Definition: JElement.hh:46
JValue_t mapped_type
Definition: JGridMap.hh:32
collection_type::const_reverse_iterator const_reverse_iterator
Definition: JGridMap.hh:41