#include <MdcSegData.h>
Public Types | |
typedef MdcMap< const MdcHit *, MdcSegUsage * > | MdcHitDict |
typedef MdcMap< const MdcHit *, MdcSegUsage * > | MdcHitDict |
Public Member Functions | |
double | bunchTime (void) const |
double | bunchTime (void) const |
const MdcHit * | hit (int hitno) const |
const MdcHit * | hit (int hitno) const |
const MdcHitMap * | hitMap () const |
const MdcHitMap * | hitMap () const |
void | loadevent (MdcHitCol *col, MdcHitMap *hmap, double tbunch) |
void | loadevent (MdcHitCol *col, MdcHitMap *hmap, double tbunch) |
MdcSegData (bool skipUsedHit) | |
MdcSegData (bool skipUsedHit) | |
int | nevent () const |
int | nevent () const |
int | nhits () const |
int | nhits () const |
void | poisonHits (const MdcDetector *gm) |
void | poisonHits (const MdcDetector *gm) |
int | runNumber () const |
int | runNumber () const |
const MdcHitDict & | segUsage () const |
const MdcHitDict & | segUsage () const |
bool | skippingUsed () const |
bool | skippingUsed () const |
virtual | ~MdcSegData () |
virtual | ~MdcSegData () |
Private Member Functions | |
MdcSegData (const MdcSegData &) | |
MdcSegData (const MdcSegData &) | |
MdcSegData & | operator= (const MdcSegData &) |
MdcSegData & | operator= (const MdcSegData &) |
Private Attributes | |
double | _bunchTime |
MdcHitMap * | _hitMap |
MdcHitMap * | _hitMap |
int | _runNumber |
MdcSegUsage * | _segUsage |
MdcSegUsage * | _segUsage |
MdcHitDict | _segUsageDict |
bool | _skipUsed |
MdcHitCol * | _theHits |
MdcHitCol * | _theHits |
int | eventNumber |
|
|
|
|
|
00018 { 00019 eventNumber=0; 00020 _segUsage = 0; 00021 _hitMap = 0; 00022 _bunchTime = 0; 00023 _skipUsed = skip; 00024 00025 _theHits = 0; 00026 }
|
|
00029 { 00030 //------------------------------------------------------------------------ 00031 delete [] _segUsage; 00032 }
|
|
|
|
|
|
|
|
|
|
00041 {return _bunchTime;}
|
|
00041 {return _bunchTime;}
|
|
|
|
00073 { 00074 //------------------------------------------------------------------------ 00075 return (*_theHits)[hitno]; 00076 }
|
|
00039 {return _hitMap;}
|
|
00039 {return _hitMap;}
|
|
|
|
00043 { 00044 //------------------------------------------------------------------------ 00045 _bunchTime = tb; 00046 _theHits = hitcol; 00047 _hitMap = hitmap; 00048 assert (_hitMap != 0); 00049 00050 _segUsageDict.clear(); 00051 delete [] _segUsage; 00052 _segUsage = 0; 00053 eventNumber++; 00054 00055 _segUsage = new MdcSegUsage[nhits()]; 00056 00057 MdcHit* aHit = 0; 00058 MdcHitCol::iterator iter = _theHits->begin(); 00059 int index = 0; 00060 for (;iter != _theHits->end(); iter++) { 00061 aHit = *iter; 00062 _segUsageDict.put(aHit, &(_segUsage[index])); 00063 if (skippingUsed() && aHit->usedHit()) { 00064 // Mark for later skipping 00065 _segUsage[index].killHit(); 00066 } 00067 index++; 00068 } 00069 }
|
|
00034 {return eventNumber;}
|
|
00034 {return eventNumber;}
|
|
|
|
00036 { 00037 //------------------------------------------------------------------------ 00038 return _theHits->size(); 00039 }
|
|
|
|
|
|
|
|
00081 { 00082 //------------------------------------------------------------------------ 00083 // Mark hits as poor candidates for segment-finding, if they are located 00084 // within a string of consecutive hits in the same layer (end hits are 00085 // not marked). 00086 for (int ilayer = 1; ilayer <= gm->nLayer(); ilayer++) { 00087 int nwire = gm->Layer(ilayer)->nWires(); 00088 for (int iwire=0; iwire < nwire;++iwire) { 00089 int wireNext = mdcWrapWire(iwire+1, nwire); 00090 if ( 0 == hitMap()->hitWire(ilayer, wireNext) ) { 00091 // 0 1 2 3 4 00092 // next wire not there: ? o ? ? ? 00093 // so the next-to-next wire shouldn't be poisened 00094 // (it's left neighbour is empty) 00095 // and the next candidate to check is + 3 00096 iwire+=2; continue; 00097 } 00098 00099 MdcHit* theHit = hitMap()->hitWire(ilayer, iwire); 00100 if (theHit == 0) { 00101 // 0 1 2 3 4 00102 // next wire is there, this one isn't : o x ? ? ? 00103 // and the next candidate to check is + 2 00104 ++iwire; continue; 00105 } 00106 00107 int wirePrev = mdcWrapWire(iwire-1, nwire); 00108 if ( 0 != hitMap()->hitWire(ilayer, wirePrev)) { 00109 segUsage().get(theHit)->killHit(); 00110 } 00111 } // end wire loop 00112 } // end layer loop 00113 00114 return; 00115 }
|
|
00036 {return _runNumber;}
|
|
00036 {return _runNumber;}
|
|
00038 {return _segUsageDict;}
|
|
00038 {return _segUsageDict;}
|
|
00042 {return _skipUsed;}
|
|
00042 {return _skipUsed;}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|