3#include "TCollection.h"
8TObjArray *TDigiEvent::s_staticMdcDigiCol = 0;
9TObjArray *TDigiEvent::s_staticCgemDigiCol = 0;
10TObjArray *TDigiEvent::s_staticEmcDigiCol = 0;
11TObjArray *TDigiEvent::s_staticTofDigiCol = 0;
12TObjArray *TDigiEvent::s_staticMucDigiCol = 0;
13TObjArray *TDigiEvent::s_staticLumiDigiCol = 0;
19 if (!s_staticMdcDigiCol) {
20 s_staticMdcDigiCol =
new TObjArray();
22 m_mdcDigiCol = s_staticMdcDigiCol;
24 if (!s_staticCgemDigiCol) {
25 s_staticCgemDigiCol =
new TObjArray();
27 m_cgemDigiCol = s_staticCgemDigiCol;
29 if (!s_staticEmcDigiCol ){
30 s_staticEmcDigiCol =
new TObjArray();
32 m_emcDigiCol = s_staticEmcDigiCol;
34 if (! s_staticTofDigiCol ){
35 s_staticTofDigiCol =
new TObjArray();
37 m_tofDigiCol = s_staticTofDigiCol;
39 if (! s_staticMucDigiCol ){
40 s_staticMucDigiCol =
new TObjArray();
42 m_mucDigiCol = s_staticMucDigiCol;
44 if (! s_staticLumiDigiCol ) {
45 s_staticLumiDigiCol =
new TObjArray();
47 m_lumiDigiCol = s_staticLumiDigiCol;
56 if(m_mdcDigiCol == s_staticMdcDigiCol) s_staticMdcDigiCol = 0;
57 m_mdcDigiCol->Delete();
61 if(m_cgemDigiCol == s_staticCgemDigiCol) s_staticCgemDigiCol = 0;
62 m_cgemDigiCol->Delete();
66 if(m_emcDigiCol == s_staticEmcDigiCol) s_staticEmcDigiCol = 0;
67 m_emcDigiCol->Delete();
71 if(m_tofDigiCol == s_staticTofDigiCol ) s_staticTofDigiCol = 0;
72 m_tofDigiCol->Delete();
76 if(m_mucDigiCol == s_staticMucDigiCol ) s_staticMucDigiCol = 0;
77 m_mucDigiCol->Delete();
81 if ( m_lumiDigiCol == s_staticLumiDigiCol ) s_staticLumiDigiCol = 0;
82 m_lumiDigiCol->Delete();
122 TObject::Print(option);
123 std::cout.precision(2);
125 std::cout <<
"Number of TMdcDigis " << m_mdcDigiCol->GetEntries() << std::endl;
127 std::cout <<
"Number of TMdcDigis 0" << std::endl;
130 std::cout <<
"Number of TCgemDigis " << m_cgemDigiCol->GetEntries() << std::endl;
132 std::cout <<
"Number of TCgemDigis 0" << std::endl;
137 m_mdcDigiCol->Add(digi);
141 if (Int_t(i) >= m_mdcDigiCol->GetEntries())
143 return (
TMdcDigi*)m_mdcDigiCol->At(i);
147 m_cgemDigiCol->Add(digi);
151 if (Int_t(i) >= m_cgemDigiCol->GetEntries())
157 m_emcDigiCol->Add(digi);
161 if(Int_t(i) >= m_emcDigiCol->GetEntries())
163 return (
TEmcDigi*)m_emcDigiCol->At(i);
168 m_tofDigiCol->Add(digi);
173 if(Int_t(i) >=m_tofDigiCol->GetEntries())
175 return (
TTofDigi*) m_tofDigiCol->At(i);
180 m_mucDigiCol->Add(digi);
185 if(Int_t(i) >=m_mucDigiCol->GetEntries())
187 return (
TMucDigi*) m_mucDigiCol->At(i);
192 m_lumiDigiCol->Add(digi);
196 if ( i >= m_lumiDigiCol->GetEntries() )
198 return (
TLumiDigi*) m_lumiDigiCol->At(i);
ClassImp(TBossFullEvent) TBossFullEvent
void addMucDigi(TMucDigi *digi)
Add a MucDigi into the MUC Data collection.
void addEmcDigi(TEmcDigi *digi)
Add a TkrDigi into the TKR data collection.
const TMucDigi * getMucDigi(Int_t i) const
retrieve a MucDigi From the collection, using the index into the array
void Print(Option_t *option="") const
void initialize(Bool_t fromMc=true)
void Clear(Option_t *option="")
const TMdcDigi * getMdcDigi(Int_t i) const
retrieve a TkrDigi from the collection, using the index into the array
void addTofDigi(TTofDigi *digi)
Add a TofDigi into the TOF Data collection.
const TEmcDigi * getEmcDigi(Int_t i) const
retrieve a EmcDigi from the collection, using the index into the array
void addMdcDigi(TMdcDigi *digi)
Add a TkrDigi into the TKR data collection.
const TLumiDigi * getLumiDigi(Int_t i) const
retrieve a LumiDigi From the collection, using the index into the array
void addLumiDigi(TLumiDigi *digi)
Add a LumiDigi into the MUC Data collection.
const TCgemDigi * getCgemDigi(Int_t i) const
retrieve a TkrDigi from the collection, using the index into the array
const TTofDigi * getTofDigi(Int_t i) const
retrieve a TofDigi From the collection, using the index into the array
void addCgemDigi(TCgemDigi *digi)
Add a TkrDigi into the TKR data collection.