Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

MdcSegData Class Reference

#include <MdcSegData.h>

List of all members.

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 MdcHithit (int hitno) const
const MdcHithit (int hitno) const
const MdcHitMaphitMap () const
const MdcHitMaphitMap () 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 MdcHitDictsegUsage () const
const MdcHitDictsegUsage () const
bool skippingUsed () const
bool skippingUsed () const
virtual ~MdcSegData ()
virtual ~MdcSegData ()

Private Member Functions

 MdcSegData (const MdcSegData &)
 MdcSegData (const MdcSegData &)
MdcSegDataoperator= (const MdcSegData &)
MdcSegDataoperator= (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


Member Typedef Documentation

typedef MdcMap<const MdcHit*,MdcSegUsage*> MdcSegData::MdcHitDict
 

typedef MdcMap<const MdcHit*,MdcSegUsage*> MdcSegData::MdcHitDict
 


Constructor & Destructor Documentation

MdcSegData::MdcSegData bool  skipUsedHit  ) 
 

00018 {
00019   eventNumber=0;
00020   _segUsage = 0;
00021   _hitMap = 0;
00022   _bunchTime = 0;
00023   _skipUsed = skip;
00024 
00025   _theHits = 0;
00026 }

MdcSegData::~MdcSegData  )  [virtual]
 

00029                             {
00030 //------------------------------------------------------------------------
00031   delete [] _segUsage;
00032 }

MdcSegData::MdcSegData const MdcSegData  )  [private]
 

MdcSegData::MdcSegData bool  skipUsedHit  ) 
 

virtual MdcSegData::~MdcSegData  )  [virtual]
 

MdcSegData::MdcSegData const MdcSegData  )  [private]
 


Member Function Documentation

double MdcSegData::bunchTime void   )  const [inline]
 

00041 {return _bunchTime;}

double MdcSegData::bunchTime void   )  const [inline]
 

00041 {return _bunchTime;}

const MdcHit* MdcSegData::hit int  hitno  )  const
 

const MdcHit * MdcSegData::hit int  hitno  )  const
 

00073                                {
00074 //------------------------------------------------------------------------
00075 return (*_theHits)[hitno];
00076 }

const MdcHitMap* MdcSegData::hitMap  )  const [inline]
 

00039 {return _hitMap;}

const MdcHitMap* MdcSegData::hitMap  )  const [inline]
 

00039 {return _hitMap;}

void MdcSegData::loadevent MdcHitCol col,
MdcHitMap hmap,
double  tbunch
 

void MdcSegData::loadevent MdcHitCol col,
MdcHitMap hmap,
double  tbunch
 

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 }

int MdcSegData::nevent  )  const [inline]
 

00034 {return eventNumber;}

int MdcSegData::nevent  )  const [inline]
 

00034 {return eventNumber;}

int MdcSegData::nhits  )  const
 

int MdcSegData::nhits  )  const
 

00036                         {
00037 //------------------------------------------------------------------------
00038   return _theHits->size();
00039 }

MdcSegData& MdcSegData::operator= const MdcSegData  )  [private]
 

MdcSegData& MdcSegData::operator= const MdcSegData  )  [private]
 

void MdcSegData::poisonHits const MdcDetector gm  ) 
 

void MdcSegData::poisonHits const MdcDetector gm  ) 
 

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 }

int MdcSegData::runNumber  )  const [inline]
 

00036 {return _runNumber;}

int MdcSegData::runNumber  )  const [inline]
 

00036 {return _runNumber;}

const MdcHitDict& MdcSegData::segUsage  )  const [inline]
 

00038 {return _segUsageDict;}

const MdcHitDict& MdcSegData::segUsage  )  const [inline]
 

00038 {return _segUsageDict;}

bool MdcSegData::skippingUsed  )  const [inline]
 

00042 {return _skipUsed;}

bool MdcSegData::skippingUsed  )  const [inline]
 

00042 {return _skipUsed;}


Member Data Documentation

double MdcSegData::_bunchTime [private]
 

MdcHitMap* MdcSegData::_hitMap [private]
 

MdcHitMap* MdcSegData::_hitMap [private]
 

int MdcSegData::_runNumber [private]
 

MdcSegUsage* MdcSegData::_segUsage [private]
 

MdcSegUsage* MdcSegData::_segUsage [private]
 

MdcHitDict MdcSegData::_segUsageDict [private]
 

bool MdcSegData::_skipUsed [private]
 

MdcHitCol* MdcSegData::_theHits [private]
 

MdcHitCol* MdcSegData::_theHits [private]
 

int MdcSegData::eventNumber [private]
 


The documentation for this class was generated from the following files:
Generated on Wed Feb 2 16:28:17 2011 for BOSS6.5.5 by  doxygen 1.3.9.1