Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Fun4AllDstInputManager.h
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file Fun4AllDstInputManager.h
1 // Tell emacs that this is a C++ source
2 // -*- C++ -*-.
3 #ifndef FUN4ALL_FUN4ALLDSTINPUTMANAGER_H
4 #define FUN4ALL_FUN4ALLDSTINPUTMANAGER_H
5 
6 #include "Fun4AllInputManager.h"
7 
8 #include <map>
9 #include <string>
10 
11 class PHCompositeNode;
12 class PHNodeIOManager;
13 class SyncObject;
14 
16 {
17  public:
18  Fun4AllDstInputManager(const std::string &name = "DUMMY", const std::string &nodename = "DST", const std::string &topnodename = "TOP");
19  ~Fun4AllDstInputManager() override;
20  int fileopen(const std::string &filenam) override;
21  int fileclose() override;
22  int run(const int nevents = 0) override;
23  int GetSyncObject(SyncObject **mastersync) override;
24  int SyncIt(const SyncObject *mastersync) override;
25  int BranchSelect(const std::string &branch, const int iflag) override;
26  int setBranches() override;
27  virtual int setSyncBranches(PHNodeIOManager *iman);
28  void Print(const std::string &what = "ALL") const override;
29  int PushBackEvents(const int i) override;
30  int HasSyncObject() const override;
31 
32  protected:
34  void ReadRunTTree(const int i) { m_ReadRunTTree = i; }
35  void IManager(PHNodeIOManager *iman) { m_IManager = iman; }
43  std::string RunNodeName() const { return RunNode; }
45 
46  private:
47  int m_ReadRunTTree = 1;
48  int events_total = 0;
49  int events_thisfile = 0;
52  std::map<const std::string, int> branchread;
59  SyncObject *syncobject = nullptr;
61 };
62 
63 #endif /* __FUN4ALLDSTINPUTMANAGER_H__ */