EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
EICG4ZDCHitTree.h
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file EICG4ZDCHitTree.h
1 #ifndef EICG4ZDCHITTREE_H
2 #define EICG4ZDCHITTREE_H
3 
4 #include <fun4all/SubsysReco.h>
5 
6 #include <map>
7 #include <set>
8 #include <string>
9 #include <vector>
10 
11 // Forward declerations
13 class PHCompositeNode;
14 class TFile;
15 class TTree;
16 
18 {
19  public:
21  EICG4ZDCHitTree(const std::string &name = "EICG4ZDCHitTree", const std::string &filename = "EICG4ZDCHitTree.root");
22 
24  ~EICG4ZDCHitTree() override;
25 
27  int Init(PHCompositeNode *) override;
28 
30  int process_event(PHCompositeNode *) override;
31 
33  int End(PHCompositeNode *) override;
34 
35  void AddNode(const std::string &name, const int detid = 0);
36 
37  protected:
38  int nblocks;
40  std::string _filename;
41  std::set<std::string> _node_postfix;
42  std::map<std::string, int> _detid;
43  TTree *tree;
44  TFile *outfile;
45 
46  private:
47 
48  int Nhit;
49 
50  std::vector<int> layerType;
51  std::vector<int> layerID;
52  std::vector<int> xID;
53  std::vector<int> yID;
54  std::vector<float> x0;
55  std::vector<float> y0;
56  std::vector<float> z0;
57  std::vector<float> x1;
58  std::vector<float> y1;
59  std::vector<float> z1;
60  std::vector<float> time0;
61  std::vector<float> time1;
62  std::vector<float> edep;
63 
64  int Ntrack;
65  std::vector<float> trk_px;
66  std::vector<float> trk_py;
67  std::vector<float> trk_pz;
68  std::vector<float> trk_e;
69  std::vector<int> trk_pid;
70 
71 
72 };
73 
74 #endif