Back to index

See source file

CExternalElectronTrackingStrategy.h

 
//----------------------------------------------------------------------------- 
//  $Header: CExternalElectronTrackingStrategy.h,v 1.3 97/05/15 12:46:46 messer Exp $ 
// 
//  COOL Program Library   
//  Copyright (C) CERES collaboration, 1996 
// 
//  Declaration of class CExternalElectronTrackingStrategy. 
// 
//  Creates all tracks according to the hits/rings of the detectors passed 
//  as arguments. Passing a detector as the null-pointer is allowed. 
//  In this case the referring detector is not included into the tracking. 
//  Detectors may be passed to the constructor or set individually. 
// 
//  NOTE: 
//  (1) 
//  The internal track lists are not automatically cleared at each 
//  call of makeTracks, thus allowing the reuse of previously 
//  reconstructed segments in the further analysis. This may save 
//  a considerable amount of time but also leaves the responsibility 
//  for clearing those lists with the user. 
//  (2) 
//  getTracks copies tracks/segments according to a bitwise OR of  
//  one or several CTrackMask masks. The result is filled 
//  into the given track list. 
//  Note, that it is the users responsibility to handle the 
//  memory allocated by the obtained tracks. 
//  'getTracks' creates a deep copy not a shallow one. 
//  example: 
//     strategy.getTracks(trackList, hasVertex|hasRich2Match); 
// 
//  The meaning of the bit mask: 	 
//  There are 3 pools of tracking information: RICH tracks, SiDC 
//  tracks and tracks consisting of matching segments. The bits 
//  'hasVertex, hasSidc1Match, hasSidc2Match' refer to Sidc tracks 
//  'hasRich1Match, hasRich2Match' to RICH tracks. If only bits of 
//  one kind are requested the referring segment pool is inspected. 
//  The returned list will contain all segments which at least have  
//  the requested bit(s) set. E.g., if you ask for 
//  'hasVertex|hasSidc2Match' there may well be segments with the 
//  hasSidc1Match bit set.  However, if a bit mask contains bits 
//  referring to RICH and SIDC only matching segments (real tracks) are 
//  returned, resolving at least the given bit pattern. 
// 
//----------------------------------------------------------------------------- 
#ifndef CEXTERNALELECTRONTRACKINGSTRATEGY_H 
#define CEXTERNALELECTRONTRACKINGSTRATEGY_H 
 
#include "cool.h" 
#include "CPadChamber.h" 
#include "CRich1.h" 
#include "CRich2.h" 
#include "CElectronTrack.h" 
#include "CSidcTrackingStrategy.h"  
    
 
class CExternalElectronTrackingStrategy : public CSidcTrackingStrategy { 
public: 
   CExternalElectronTrackingStrategy(CVertex*, CSidc*, CSidc*, CRich1*, CRich2*, CPadChamber*, 
				     const char* = 0);  
   ~CExternalElectronTrackingStrategy();  
    
   CBoolean makeTracks(); 
   CBoolean getTracks(CSortedList<CElectronTrack>&, unsigned long); 
 
   void clearRichPadcTracks() { if (richPadcTracks) richPadcTracks->clearAndDestroy(); } 
    
   void	setRich1(CRich1* ptr) { rich1 = ptr; } 
   void	setRich2(CRich2* ptr) { rich2 = ptr; } 
   void setPadChamber(CPadChamber* ptr) { padChamber = ptr; } 
       
protected:    
   virtual CBoolean makeRichPadcTracks(); 
   virtual CBoolean linkAllTracks(); 
    
protected: 
   const CRich1*      rich1; 
   const CRich2*      rich2; 
   const CPadChamber* padChamber; 
   CList<CElectronTrack> *richPadcTracks; 
   CSortedList<CElectronTrack> *tracks; 
};    
			      
#endif /* CEXTERNALELECTRONTRACKINGSTRATEGY_H */ 

Back to index

See source file