BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
Reconstruction/MdcPatRec/TrkBase/include/TrkBase/TrkFitMaker.h
Go to the documentation of this file.
1//--------------------------------------------------------------------------
2// File and Version Information:
3// $Id: TrkFitMaker.h,v 1.2 2007/11/13 07:27:23 codeman Exp $
4//
5// Description: Abstract base class for FitMaker classes. FitMakers have
6// two functions, and only FitMakers are supposed to perform these
7// functions: 1) creating tracks and 2) changing the TrkRep + Fitter
8// combination for a track.
9// Derived classes may have data members -- e.g. cut values
10// to be set in created fitters.
11// Derived classes usually implement something like these functions:
12// TrkRecoTrk* makeTrack(const TrkExchangePar& helix, const
13// HepAList<TrkHitOnTrk>* hotList, double chi2=-999.);
14// virtual void changeFit(TrkRecoTrk& theTrack) const = 0;
15//
16// But I've found too many exceptions to make these virtual functions.
17// So what this class really does is give friendship access to TrkRecoTrks,
18// and permits derived classes to muck about to their hearts' content.
19//
20// Environment:
21// Software developed for the BaBar Detector at the SLAC B-Factory.
22//
23// Authors: Steve Schaffner
24//
25//------------------------------------------------------------------------
26#ifndef TRKFITMAKER_HH
27#define TRKFITMAKER_HH
28#include "MdcRecoUtil/PdtPid.h"
29#include "TrkBase/TrkRep.h"
30#include <utility>
31
32class TrkHitOnTrk;
33class TrkRep;
34class TrkRecoTrk;
35class TrkExchangePar;
36class TrkContext;
37class TrkIdManager;
38namespace MdcPatRec {
39 class BField;
40}
41class TrkRepIter;
42class KalMiniTrkK;
43
44// Class interface //
45class TrkFitMaker {
46
47public:
48 virtual ~TrkFitMaker();
49
51
52protected:
53 // The following functions provide friendship access to TrkRecoTrk
54 // (including to ctor).
55 // gets current TrkReps from track:
56 std::pair<TrkRepIter, TrkRepIter> uniqueReps( const TrkRecoTrk& t ) const; // was currentReps
57 void setRep( TrkRecoTrk&, TrkRep* ) const;
60 std::pair<TrkRepIter, TrkRepIter> allReps( const TrkRecoTrk& t ) const; // was repPtrs
63 TrkRecoTrk* createTrack( PdtPid::PidType, const TrkContext&, double t0 ) const;
64 TrkRecoTrk* createTrack( PdtPid::PidType, long idnum, double t0 ) const;
65 // the following functions try to cover the fact that the
66 // persistence model is completely incompatible with the tracking design.
67 // They allow direct manipulation of what should be private or constructor-supplied
68 // arguments.
70 void setBField( TrkRecoTrk&, const MdcPatRec::BField* ) const;
71 // allow persistence to call these functions
72 friend class KalMiniTrkK;
73 friend class KalMiniRX;
74 friend class KalFit;
75};
76
77#endif
void setIdManager(TrkRecoTrk &, TrkIdManager *) const
std::pair< TrkRepIter, TrkRepIter > allReps(const TrkRecoTrk &t) const
void addHypoTo(TrkRecoTrk &, TrkRep *, PdtPid::PidType hypo) const
std::pair< TrkRepIter, TrkRepIter > uniqueReps(const TrkRecoTrk &t) const
TrkRep * getRep(TrkRecoTrk &, PdtPid::PidType) const
void repointHypo(TrkRecoTrk &, PdtPid::PidType hypo, PdtPid::PidType fit) const
virtual ~TrkFitMaker()
void setRep(TrkRecoTrk &, TrkRep *) const
TrkRecoTrk * createTrack(PdtPid::PidType, const TrkContext &, double t0) const
void changeDefault(TrkRecoTrk &, PdtPid::PidType) const
TrkRecoTrk * createTrack(PdtPid::PidType, long idnum, double t0) const
void setFitNumber(TrkRecoTrk &, PdtPid::PidType, int) const
void setBField(TrkRecoTrk &, const MdcPatRec::BField *) const
int t()
Definition t.c:1