ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
EICG4ZDCNtuple.h
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file EICG4ZDCNtuple.h
1 #ifndef EICG4ZDCNTUPLE_H
2 #define EICG4ZDCNTUPLE_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 TNtuple;
16 
17 class EICG4ZDCNtuple : public SubsysReco
18 {
19  public:
21  EICG4ZDCNtuple(const std::string &name = "EICG4ZDCNtuple", const std::string &filename = "EICG4ZDCNtuple.root");
22 
24  ~EICG4ZDCNtuple() 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  TNtuple *ntup;
44  TFile *outfile;
45 };
46 
47 #endif