PandaRoot
BSEmcFwEndcapIdealDigitizerProcess.h
Go to the documentation of this file.
1 #ifndef BSEMCFWENDCAPIDEALDIGITIZER_HH
2 #define BSEMCFWENDCAPIDEALDIGITIZER_HH
3 #include <algorithm>
4 #include <memory>
5 #include <string>
6 #include <vector>
7 
8 #include "Rtypes.h"
9 #include "RtypesCore.h"
10 
11 #include "PndContainerI.h"
12 #include "PndParameterRegister.h"
13 #include "PndProcess.h"
14 
16 
17 class TClonesArray;
18 class BSEmcDigiPar;
19 class BSEmcMCHit;
20 class BSEmcDigi;
23 class TBuffer;
24 class TClass;
25 class TMemberInspector;
26 template <class T>
27 class PndInputContainerI;
28 template <class T>
30 
39 class BSEmcFwEndcapIdealDigitizerProcess : public PndProcess<BSEmcDigitizationData> {
40  public:
43 
44  virtual void SetDetectorName(const std::string &t_detectorName) /*override*/;
45  virtual void SetupParameters(const PndParameterRegister *t_parameterRegister) /*override*/;
46  virtual void SetData(BSEmcDigitizationData *t_data) /*override*/;
47  virtual void Process() /*override*/;
48 
49  void SetVpttIds(const std::vector<Int_t> &t_vpttIds)
50  {
51  fVpttIds = t_vpttIds;
52  std::sort(fVpttIds.begin(), fVpttIds.end());
53  }
54 
55  protected:
56  virtual Bool_t IsVpttHit(const BSEmcMCHit *t_hit) const;
57 
58  private:
59  PndInputContainerI<BSEmcMCHit> *fHitArray{nullptr};
60  PndOutputContainerI<BSEmcDigi> *fDigiArray{nullptr};
61 
62  std::unique_ptr<BSEmcIdealDigitizationProcess> fAPDDigitizer{new BSEmcIdealDigitizationProcess()};
63  std::unique_ptr<BSEmcIdealDigitizationProcess> fVPTDigitizer{new BSEmcIdealDigitizationProcess()};
64  std::vector<Int_t> fVpttIds{}; // searching a vector for each hit is bad. Need a different approach.
65 
67 };
68 
69 #endif /*BSEMCFWENDCAPIDEALDIGITIZER_HH*/
Base Process class.
Definition: PndProcess.h:24
Smears BSEmcMCHit energy and forms BSEmcDigi if energy above threshold.
virtual Bool_t IsVpttHit(const BSEmcMCHit *t_hit) const
IdealDigitizationProcess (non waveform) for FwEndcap requires special treatment since the FwEndcap ha...
represents the reconstructed hit of one emc crystal
Definition: BSEmcDigi.h:47
virtual void SetupParameters(const PndParameterRegister *t_parameterRegister)
Fetch all parameters from the PndParameterRegister.
virtual void SetData(BSEmcDigitizationData *t_data)
Pass the data container ptrs to the process, and store pointers in class members. ...
Interface to a datacontainer to be used in PandaROOT.
virtual void Process()
The actual data transformation (digitizing, clustering, etc.) should be defined here.
void SetVpttIds(const std::vector< Int_t > &t_vpttIds)
virtual void SetDetectorName(const std::string &t_detectorName)
Set the Detector name. Important, as most EmcParameter need to know for which detector they need to b...
Helper class to indirect the Parameter fetching via the FairRuntimeDb.
represents the deposited energy of one emc crystal from simulation
Definition: BSEmcMCHit.h:32
Container for runtime parameters that are required for the transformation from BSEmcMCHits to BSEmcDi...
Definition: BSEmcDigiPar.h:23
DataStruct to pass addresses to data Container between BSEmcDigitizerTask and PndProcess<BSEmcDigitiz...