////////////////////////////////////////////////////////// // This class has been automatically generated on // Wed May 16 17:40:18 2012 by ROOT version 5.26/00g // from TTree TreeVar/Physiscs Variables // found on file: ./../data/Tree/Tree_Mod12_ScfCal_Run7369-Run7395.root ////////////////////////////////////////////////////////// #ifndef miselector_h #define miselector_h #include #include #include #include #define MaxHits 11 class miselector : public TSelector { public : TTree *fChain; //!pointer to the analyzed TTree or TChain //Int_t** HitsL; Int_t HitsL[MaxHits][MaxHits]; // Declaration of leaf types Int_t NrRun; Int_t NrHits_1; Int_t LYSO_NrHit1; Int_t WLS_NrHit1; Int_t Chan_1[44]; //[NrHits1] Int_t NrHits_2; Int_t LYSO_NrHit2; Int_t WLS_NrHit2; Int_t Chan_2[24]; //[NrHits2] vector *LYSO_x1; vector *LYSO_y1; vector *LYSO_adc1; vector *LYSO_Ene_TCorr1; vector *WLS_x1; vector *WLS_z1; vector *WLS_adc1; vector *WLS_Npe_TCorr1; vector *LYSO_x2; vector *LYSO_y2; vector *LYSO_adc2; vector *LYSO_Ene_TCorr2; vector *WLS_x2; vector *WLS_z2; vector *WLS_adc2; vector *WLS_Npe_TCorr2; Int_t WLS_NrClu1; vector *WLS_SizeClu1; vector *WLS_LayClu1; vector *WLS_SumClu1; vector *WLS_ZcgClu1; Int_t WLS_NrClu2; vector *WLS_SizeClu2; vector *WLS_LayClu2; vector *WLS_SumClu2; vector *WLS_ZcgClu2; // List of branches TBranch *b_RunNr; //! TBranch *b_NrHits1; //! TBranch *b_NrHitL1; //! TBranch *b_NrHitW1; //! TBranch *b_Chan_1; //! TBranch *b_NrHits2; //! TBranch *b_NrHitL2; //! TBranch *b_NrHitW2; //! TBranch *b_Chan_2; //! TBranch *b_LYSO_x1; //! TBranch *b_LYSO_y1; //! TBranch *b_LYSO_adc1; //! TBranch *b_LYSO_Ene_TCorr1; //! TBranch *b_WLS_x1; //! TBranch *b_WLS_z1; //! TBranch *b_WLS_adc1; //! TBranch *b_WLS_Npe_TCorr1; //! TBranch *b_LYSO_x2; //! TBranch *b_LYSO_y2; //! TBranch *b_LYSO_adc2; //! TBranch *b_LYSO_Ene_TCorr2; //! TBranch *b_WLS_x2; //! TBranch *b_WLS_z2; //! TBranch *b_WLS_adc2; //! TBranch *b_WLS_Npe_TCorr2; //! TBranch *b_NrWlsClu1; //! TBranch *b_WLS_SizeClu1; //! TBranch *b_WLS_LayClu1; //! TBranch *b_WLS_SumClu1; //! TBranch *b_WLS_ZcgClu1; //! TBranch *b_NrWlsClu2; //! TBranch *b_WLS_SizeClu2; //! TBranch *b_WLS_LayClu2; //! TBranch *b_WLS_SumClu2; //! TBranch *b_WLS_ZcgClu2; //! miselector(TTree * /*tree*/ =0) { } virtual ~miselector() { } virtual Int_t Version() const { return 2; } virtual void Begin(TTree *tree); virtual void SlaveBegin(TTree *tree); virtual void Init(TTree *tree); virtual Bool_t Notify(); virtual Bool_t Process(Long64_t entry); virtual Int_t GetEntry(Long64_t entry, Int_t getall = 0) { return fChain ? fChain->GetTree()->GetEntry(entry, getall) : 0; } virtual void SetOption(const char *option) { fOption = option; } virtual void SetObject(TObject *obj) { fObject = obj; } virtual void SetInputList(TList *input) { fInput = input; } virtual TList *GetOutputList() const { return fOutput; } virtual void SlaveTerminate(); virtual void Terminate(); virtual void menormayor(Int_t , Int_t , Int_t &, Int_t &); ClassDef(miselector,0); }; #endif #ifdef miselector_cxx void miselector::Init(TTree *tree) { // The Init() function is called when the selector needs to initialize // a new tree or chain. Typically here the branch addresses and branch // pointers of the tree will be set. // It is normally not necessary to make changes to the generated // code, but the routine can be extended by the user if needed. // Init() will be called many times when running on PROOF // (once per file to be processed). // Set object pointer //HitsL=0; LYSO_x1 = 0; LYSO_y1 = 0; LYSO_adc1 = 0; LYSO_Ene_TCorr1 = 0; WLS_x1 = 0; WLS_z1 = 0; WLS_adc1 = 0; WLS_Npe_TCorr1 = 0; LYSO_x2 = 0; LYSO_y2 = 0; LYSO_adc2 = 0; LYSO_Ene_TCorr2 = 0; WLS_x2 = 0; WLS_z2 = 0; WLS_adc2 = 0; WLS_Npe_TCorr2 = 0; WLS_SizeClu1 = 0; WLS_LayClu1 = 0; WLS_SumClu1 = 0; WLS_ZcgClu1 = 0; WLS_SizeClu2 = 0; WLS_LayClu2 = 0; WLS_SumClu2 = 0; WLS_ZcgClu2 = 0; // Set branch addresses and branch pointers if (!tree) return; fChain = tree; fChain->SetMakeClass(1); fChain->SetBranchAddress("NrRun", &NrRun, &b_RunNr); fChain->SetBranchAddress("NrHits_1", &NrHits_1, &b_NrHits1); fChain->SetBranchAddress("LYSO_NrHit1", &LYSO_NrHit1, &b_NrHitL1); fChain->SetBranchAddress("WLS_NrHit1", &WLS_NrHit1, &b_NrHitW1); fChain->SetBranchAddress("Chan_1", Chan_1, &b_Chan_1); fChain->SetBranchAddress("NrHits_2", &NrHits_2, &b_NrHits2); fChain->SetBranchAddress("LYSO_NrHit2", &LYSO_NrHit2, &b_NrHitL2); fChain->SetBranchAddress("WLS_NrHit2", &WLS_NrHit2, &b_NrHitW2); fChain->SetBranchAddress("Chan_2", Chan_2, &b_Chan_2); fChain->SetBranchAddress("LYSO_x1", &LYSO_x1, &b_LYSO_x1); fChain->SetBranchAddress("LYSO_y1", &LYSO_y1, &b_LYSO_y1); fChain->SetBranchAddress("LYSO_adc1", &LYSO_adc1, &b_LYSO_adc1); fChain->SetBranchAddress("LYSO_Ene_TCorr1", &LYSO_Ene_TCorr1, &b_LYSO_Ene_TCorr1); fChain->SetBranchAddress("WLS_x1", &WLS_x1, &b_WLS_x1); fChain->SetBranchAddress("WLS_z1", &WLS_z1, &b_WLS_z1); fChain->SetBranchAddress("WLS_adc1", &WLS_adc1, &b_WLS_adc1); fChain->SetBranchAddress("WLS_Npe_TCorr1", &WLS_Npe_TCorr1, &b_WLS_Npe_TCorr1); fChain->SetBranchAddress("LYSO_x2", &LYSO_x2, &b_LYSO_x2); fChain->SetBranchAddress("LYSO_y2", &LYSO_y2, &b_LYSO_y2); fChain->SetBranchAddress("LYSO_adc2", &LYSO_adc2, &b_LYSO_adc2); fChain->SetBranchAddress("LYSO_Ene_TCorr2", &LYSO_Ene_TCorr2, &b_LYSO_Ene_TCorr2); fChain->SetBranchAddress("WLS_x2", &WLS_x2, &b_WLS_x2); fChain->SetBranchAddress("WLS_z2", &WLS_z2, &b_WLS_z2); fChain->SetBranchAddress("WLS_adc2", &WLS_adc2, &b_WLS_adc2); fChain->SetBranchAddress("WLS_Npe_TCorr2", &WLS_Npe_TCorr2, &b_WLS_Npe_TCorr2); fChain->SetBranchAddress("WLS_NrClu1", &WLS_NrClu1, &b_NrWlsClu1); fChain->SetBranchAddress("WLS_SizeClu1", &WLS_SizeClu1, &b_WLS_SizeClu1); fChain->SetBranchAddress("WLS_LayClu1", &WLS_LayClu1, &b_WLS_LayClu1); fChain->SetBranchAddress("WLS_SumClu1", &WLS_SumClu1, &b_WLS_SumClu1); fChain->SetBranchAddress("WLS_ZcgClu1", &WLS_ZcgClu1, &b_WLS_ZcgClu1); fChain->SetBranchAddress("WLS_NrClu2", &WLS_NrClu2, &b_NrWlsClu2); fChain->SetBranchAddress("WLS_SizeClu2", &WLS_SizeClu2, &b_WLS_SizeClu2); fChain->SetBranchAddress("WLS_LayClu2", &WLS_LayClu2, &b_WLS_LayClu2); fChain->SetBranchAddress("WLS_SumClu2", &WLS_SumClu2, &b_WLS_SumClu2); fChain->SetBranchAddress("WLS_ZcgClu2", &WLS_ZcgClu2, &b_WLS_ZcgClu2); } Bool_t miselector::Notify() { // The Notify() function is called when a new file is opened. This // can be either for a new TTree in a TChain or when when a new TTree // is started when using PROOF. It is normally not necessary to make changes // to the generated code, but the routine can be extended by the // user if needed. The return value is currently not used. return kTRUE; } #endif // #ifdef miselector_cxx