#ifndef __HPARTICLEBOOKER_H__ #define __HPARTICLEBOOKER_H__ #include "hparticlecand.h" #include #include using namespace std; class HParticleBooker; class HTofHit; class HTofCluster; class HRpcCluster; class HShowerHit; class HMdcSeg; class HRichHit; R__EXTERN HParticleBooker *gParticleBooker; class HParticleBooker : public TObject { private: map > mTofHittoCand; //! TOF hit lookup detector hit ind -> list of candidates using this hit map > mTofClsttoCand; //! TOF cluster lookup detector hit ind -> list of candidates using this hit map > mRpcClsttoCand; //! RPC cluster lookup detector hit ind -> list of candidates using this hit map > mShowertoCand; //! SHOWER hit lookup detector hit ind -> list of candidates using this hit map > mInnerMdctoCand; //! inner Seg lookup detector hit ind -> list of candidates using this hit map > mOuterMdctoCand; //! outer Seg lookup detector hit ind -> list of candidates using this hit map > mRichtoCand; //! RICH hit lookup detector hit ind -> list of candidates using this hit vector vTofHitInd; vector vTofClstInd; vector vRpcClstInd; vector vShowerInd; vector vInnerMdcInd; vector vOuterMdcInd; vector vRichInd; vector vTofHit; vector vTofClst; vector vRpcClst; vector vShower; vector vInnerMdc; vector vOuterMdc; vector vRich; vector vTofHitAll; vector vTofClstAll; vector vRpcClstAll; vector vShowerAll; vector vInnerMdcAll; vector vOuterMdcAll; vector vRichAll; void bookHits(HParticleCand* cand1); public: HParticleBooker(); ~HParticleBooker(); void nextEvent(); vector& getTofHitIndices() { return vTofHitInd; } vector& getTofClstIndices() { return vTofClstInd; } vector& getRpcClstIndices() { return vRpcClstInd; } vector& getShowerIndices() { return vShowerInd; } vector& getInnerMdcIndices() { return vInnerMdcInd; } vector& getOuterMdcIndices() { return vOuterMdcInd; } vector& getRichIndices() { return vRichInd; } map >& getTofHitMap() { return mTofHittoCand; } map >& getTofClstMap() { return mTofClsttoCand; } map >& getRpcClstMap() { return mRpcClsttoCand; } map >& getShowerHitMap(){ return mShowertoCand; } map >& getInnerMdcMap() { return mInnerMdctoCand; } map >& getOuterMdcMap() { return mOuterMdctoCand; } map >& getRichMap() { return mRichtoCand; } Int_t getCandidatesForTofHit (Int_t index,vector& cands); Int_t getCandidatesForTofCluster(Int_t index,vector& cands); Int_t getCandidatesForRpcCluster(Int_t index,vector& cands); Int_t getCandidatesForShower (Int_t index,vector& cands); Int_t getCandidatesForInnerMdc (Int_t index,vector& cands); Int_t getCandidatesForOuterMdc (Int_t index,vector& cands); Int_t getCandidatesForRich (Int_t index,vector& cands); vector& getTofHits () { return vTofHit; } vector& getTofClusters () { return vTofClst; } vector& getRpcClusters () { return vRpcClst; } vector& getShowerHits () { return vShower; } vector& getInnerMdcSegs() { return vInnerMdc;} vector& getOuterMdcSegs() { return vOuterMdc;} vector& getRichHits () { return vRich; } vector& getAllTofHits () { return vTofHitAll; } vector& getAllTofClusters () { return vTofClstAll; } vector& getAllRpcClusters () { return vRpcClstAll; } vector& getAllShowerHits () { return vShowerAll; } vector& getAllInnerMdcSegs() { return vInnerMdcAll;} vector& getAllOuterMdcSegs() { return vOuterMdcAll;} vector& getAllRichHits () { return vRichAll; } Int_t getSameRich (HParticleCand* cand,vector& candidates,UInt_t flag=0,Bool_t isReference=kTRUE); Int_t getSameInnerMdc(HParticleCand* cand,vector& candidates,UInt_t flag=0,Bool_t isReference=kTRUE); Int_t getSameOuterMdc(HParticleCand* cand,vector& candidates,UInt_t flag=0,Bool_t isReference=kTRUE); Int_t getSameMeta (HParticleCand* cand,vector& candidates,UInt_t flag=0,Bool_t isReference=kTRUE); Int_t getSameAny (HParticleCand* cand,vector& candidates,UInt_t flag=0,UInt_t detswitch=0,Bool_t isReference=kTRUE); ClassDef(HParticleBooker,0) }; #endif