ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
RawClusterContainer.h
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file RawClusterContainer.h
1 #ifndef CALOBASE_RAWCLUSTERCONTAINER_H
2 #define CALOBASE_RAWCLUSTERCONTAINER_H
3 
4 #include "RawClusterDefs.h"
5 
6 #include <phool/PHObject.h>
7 
8 #include <iostream>
9 #include <map>
10 #include <utility>
11 
12 class RawCluster;
13 
15 {
16  public:
17  typedef std::map<RawClusterDefs::keytype, RawCluster *> Map;
18  typedef Map::iterator Iterator;
19  typedef Map::const_iterator ConstIterator;
20  typedef std::pair<Iterator, Iterator> Range;
21  typedef std::pair<ConstIterator, ConstIterator> ConstRange;
22 
24  ~RawClusterContainer() override {}
25 
26  void Reset() override;
27  int isValid() const override;
28  void identify(std::ostream &os = std::cout) const override;
29 
31 
33  const RawCluster *getCluster(const RawClusterDefs::keytype id) const;
34 
36  ConstRange getClusters(void) const;
37  Range getClusters(void);
38  const Map &getClustersMap() const { return _clusters; }
39  Map &getClustersMap() { return _clusters; }
40 
41  unsigned int size() const { return _clusters.size(); }
42  double getTotalEdep() const;
43 
44  protected:
46 
47  ClassDefOverride(RawClusterContainer, 1)
48 };
49 
50 #endif