LDMX Software
IntermediateCluster.h
1/*
2 IntermediateCluster -- In-memory tool for working on clusters
3 */
4#ifndef ECAL_WORKINGCLUSTER_H_
5#define ECAL_WORKINGCLUSTER_H_
6
7#include <iostream>
8#include <vector>
9
11#include "Ecal/Event/EcalHit.h"
12#include "TLorentzVector.h"
13
14namespace ecal {
15
17 public:
18 IntermediateCluster(const ldmx::EcalHit& eh, int layer = -1);
19 IntermediateCluster() = default;
20 ~IntermediateCluster() = default;
21 void add(const ldmx::EcalHit& eh);
22 void add(const ldmx::EcalHit* eh);
23 void add(const IntermediateCluster& wc);
24 const ROOT::Math::XYZTVector& centroid() const { return centroid_; }
25 std::vector<const ldmx::EcalHit*> getHits() const { return hits_; }
26 bool empty() const { return hits_.empty(); }
27 void clear() { hits_.clear(); }
28 int getLayer() const;
29 void setLayer(int layer);
30
31 private:
32 int layer_;
33 std::vector<const ldmx::EcalHit*> hits_;
34 ROOT::Math::XYZTVector centroid_;
35};
36} // namespace ecal
37
38#endif
Class that translates raw positions of ECal module hits into cells in a hexagonal readout.
Stores reconstructed hit information from the ECAL.
Definition EcalHit.h:19