Jpp test-rotations-old
the software that should make you happy
Loading...
Searching...
No Matches
JAbstractMultiMap.hh
Go to the documentation of this file.
1#ifndef __JTOOLS__JABSTRACTMULTIMAP__
2#define __JTOOLS__JABSTRACTMULTIMAP__
3
5#include "JTools/JMultiKey.hh"
6
7
8/**
9 * \author mdejong
10 */
11
12namespace JTOOLS {}
13namespace JPP { using namespace JTOOLS; }
14
15namespace JTOOLS {
16
17 /**
18 * Abstract interface for abscissa values of a multidimensional map.
19 *
20 * The template parameters refer to the dimension of the multimap and
21 * the data type of the abscissa values, respectively.
22 */
23 template<unsigned int N, class JAbscissa_t>
25 public virtual JAbstractMultiMap<N - 1, JAbscissa_t>
26 {
27 typedef JAbscissa_t abscissa_type;
29
30 using JAbstractMultiMap<N - 1, JAbscissa_t>::operator();
31
32
33 /**
34 * Virtual destructor.
35 */
37 {}
38
39
40 /**
41 * Get abscissa values as a function of given key.
42 *
43 * \param key key
44 * \return abscissa values
45 */
46 virtual const JAbstractCollection<abscissa_type>& operator()(const key_type& key) const = 0;
47 };
48
49
50 /**
51 * Terminator class of recursive class JAbstractMultiMap.
52 * This class provides for dummy implementations of interface methods.
53 */
54 template<class JAbscissa_t>
55 struct JAbstractMultiMap<0, JAbscissa_t>
56 {
57 protected:
58 void operator()() const {}
59 };
60}
61
62#endif
Multidimensional key.
Definition JMultiKey.hh:69
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
Auxiliary classes and methods for multi-dimensional interpolations and histograms.
Abstract interface for abscissa values of a collection of elements.
Abstract interface for abscissa values of a multidimensional map.
virtual const JAbstractCollection< abscissa_type > & operator()(const key_type &key) const =0
Get abscissa values as a function of given key.
virtual ~JAbstractMultiMap()
Virtual destructor.
JMultiKey< N - 1, abscissa_type > key_type