StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StHbtManager.h
1 /***************************************************************************
2  *
3  * $Id: StHbtManager.h,v 1.10 2000/03/17 17:23:05 laue Exp $
4  *
5  * Author: Mike Lisa, Ohio State, lisa@mps.ohio-state.edu
6  ***************************************************************************
7  *
8  * Description: part of STAR HBT Framework: StHbtMaker package
9  * The Manager is the top-level object that coordinates activities
10  * and performs event, particle, and pair loops, and checks the
11  * various Cuts of the Analyses in its AnalysisCollection
12  *
13  ***************************************************************************
14  *
15  * $Log: StHbtManager.h,v $
16  * Revision 1.10 2000/03/17 17:23:05 laue
17  * Roberts new three particle correlations implemented.
18  *
19  * Revision 1.9 2000/02/18 21:32:24 laue
20  * franksTrackCut changed. If mCharge is set to '0' there will be no cut
21  * on charge. This is important for front-loaded cuts.
22  *
23  * copy constructor implemented for StHbtEvent, StHbtTrack and StHbtV0.
24  *
25  * franks1HistoD.cxx franks1HistoD.h franks2HistoD.cxx franks2HistoD.h
26  * removed. We can now (CC5 on Solaris) use the versions (no D)
27  *
28  * Revision 1.8 2000/01/25 17:35:17 laue
29  * I. In order to run the stand alone version of the StHbtMaker the following
30  * changes have been done:
31  * a) all ClassDefs and ClassImps have been put into #ifdef __ROOT__ statements
32  * b) unnecessary includes of StMaker.h have been removed
33  * c) the subdirectory StHbtMaker/doc/Make has been created including everything
34  * needed for the stand alone version
35  *
36  * II. To reduce the amount of compiler warning
37  * a) some variables have been type casted
38  * b) some destructors have been declared as virtual
39  *
40  * Revision 1.7 1999/10/04 15:38:58 lisa
41  * include Franks new accessor methods StHbtAnalysis::CorrFctn and StHbtManager::Analysis as well as McEvent example macro
42  *
43  * Revision 1.6 1999/09/24 01:23:12 fisyak
44  * Reduced Include Path
45  *
46  * Revision 1.5 1999/09/08 04:15:52 lisa
47  * persistent microDST implementation tweaked to please fickle solaris details
48  *
49  * Revision 1.4 1999/09/05 02:58:12 lisa
50  * add ASCII microDST reader/writer AND franksParticle cuts
51  *
52  * Revision 1.3 1999/09/04 04:41:02 lisa
53  * StHbtEvent IO --and-- StHbtEventWriter (microDST) method added to framework
54  *
55  * Revision 1.2 1999/07/06 22:33:22 lisa
56  * Adjusted all to work in pro and new - dev itself is broken
57  *
58  * Revision 1.1.1.1 1999/06/29 16:02:57 lisa
59  * Installation of StHbtMaker
60  *
61  **************************************************************************/
62 
63 #ifndef StHbtManager_hh
64 #define StHbtManager_hh
65 
66 
67 #include "StHbtMaker/Infrastructure/StHbtTypes.hh"
68 #include "StHbtMaker/Infrastructure/StHbtAnalysisCollection.hh"
69 #include "StHbtMaker/Infrastructure/StHbtEventWriterCollection.hh"
70 #include "StHbtMaker/Infrastructure/StHbtEvent.hh"
71 #include "StHbtMaker/Base/StHbtBaseAnalysis.h"
72 #include "StHbtMaker/Base/StHbtEventReader.hh"
73 #include "StHbtMaker/Base/StHbtEventWriter.hh"
74 
76 
77 private:
78  StHbtAnalysisCollection* mAnalysisCollection;
79  StHbtEventReader* mEventReader;
80  StHbtEventWriterCollection* mEventWriterCollection;
81 
82 public:
83  StHbtManager();
84  virtual ~StHbtManager();
85 
86  // Gets and Sets...
87  StHbtAnalysisCollection* AnalysisCollection();
88  StHbtBaseAnalysis* Analysis(int n); // Access to Analysis within Collection
89  void AddAnalysis(StHbtBaseAnalysis*);
90 
91  StHbtEventWriterCollection* EventWriterCollection();
92  StHbtEventWriter* EventWriter(int n);// Access to EventWriter within Collection
93  void SetEventWriter(StHbtEventWriter*); // just for historic reasons
94  void AddEventWriter(StHbtEventWriter*);
95 
97  void SetEventReader(StHbtEventReader*);
98 
99 
100  int Init();
101  int ProcessEvent(); // a "0" return value means success - otherwise quit
102  void Finish();
103 
104  StHbtString Report();
105 #ifdef __ROOT__
106  ClassDef(StHbtManager, 0)
107 #endif
108 };
109 
110 inline StHbtAnalysisCollection* StHbtManager::AnalysisCollection(){return mAnalysisCollection;}
111 inline void StHbtManager::AddAnalysis(StHbtBaseAnalysis* anal){mAnalysisCollection->push_back(anal);}
112 
113 inline StHbtEventWriterCollection* StHbtManager::EventWriterCollection(){return mEventWriterCollection;}
114 inline void StHbtManager::AddEventWriter(StHbtEventWriter* writer){mEventWriterCollection->push_back(writer);}
115 inline void StHbtManager::SetEventWriter(StHbtEventWriter* writer){mEventWriterCollection->push_back(writer);}
116 
117 inline StHbtEventReader* StHbtManager::EventReader(){return mEventReader;}
118 inline void StHbtManager::SetEventReader(StHbtEventReader* reader){mEventReader = reader;}
119 
120 
121 #endif
122