File indexing completed on 2025-08-05 08:11:59
0001
0002
0003 #ifndef SYNRADANA_H
0004 #define SYNRADANA_H
0005
0006 #include <fun4all/SubsysReco.h>
0007
0008 #include <string>
0009 #include <vector>
0010
0011 class PHCompositeNode;
0012 class Fun4AllHistoManager;
0013
0014 class SynRadAna : public SubsysReco
0015 {
0016 public:
0017 SynRadAna(const std::string &filename = "SynRadAna.root");
0018
0019 virtual ~SynRadAna();
0020
0021
0022
0023
0024
0025
0026 int Init(PHCompositeNode *topNode) override;
0027
0028
0029
0030
0031
0032
0033 int InitRun(PHCompositeNode *topNode) override;
0034
0035
0036
0037
0038 int process_event(PHCompositeNode *topNode) override;
0039
0040
0041 int ResetEvent(PHCompositeNode *topNode) override;
0042
0043
0044 int EndRun(const int runnumber) override;
0045
0046
0047 int End(PHCompositeNode *topNode) override;
0048
0049
0050 int Reset(PHCompositeNode * ) override;
0051
0052 void Print(const std::string &what = "ALL") const override;
0053
0054
0055
0056
0057
0058 int get_embedding_id() const { return _embedding_id; }
0059
0060
0061
0062
0063
0064 void set_embedding_id(int id) { _embedding_id = id; }
0065
0066 void
0067 AddNode(const std::string &name)
0068 {
0069 _node_postfix.push_back(name);
0070 }
0071
0072 void
0073 AddHit(const std::string &name)
0074 {
0075 _node_postfix.push_back(name);
0076 }
0077
0078 void
0079 AddTower(const std::string &name)
0080 {
0081 _tower_postfix.push_back(name);
0082 }
0083
0084 bool isDoMvtxHits() const
0085 {
0086 return do_MVTXHits;
0087 }
0088
0089 void setDoMvtxHits(bool doMvtxHits)
0090 {
0091 do_MVTXHits = doMvtxHits;
0092 }
0093
0094 bool isDoTPCHits() const
0095 {
0096 return do_TPCHits;
0097 }
0098
0099 void setDoTPCHits(bool doTPCHits)
0100 {
0101 do_TPCHits = doTPCHits;
0102 }
0103
0104 bool isDoPhoton() const
0105 {
0106 return do_photon;
0107 }
0108
0109 void setDoPhoton(bool doPhoton)
0110 {
0111 do_photon = doPhoton;
0112 }
0113
0114 private:
0115
0116
0117
0118 int _embedding_id;
0119
0120 double m_eventWeight;
0121
0122 bool do_photon;
0123 bool do_MVTXHits;
0124 bool do_TPCHits;
0125
0126 std::string m_outputFIle;
0127
0128 std::vector<std::string> _node_postfix;
0129 std::vector<std::string> _tower_postfix;
0130
0131 Fun4AllHistoManager *
0132 getHistoManager();
0133
0134
0135 std::string get_histo_prefix();
0136 };
0137
0138 #endif