00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013 #ifndef TMFITTER_FLAG_
00014 #define TMFITTER_FLAG_
00015
00016 #ifdef TRKRECO_DEBUG_DETAIL
00017 #ifndef TRKRECO_DEBUG
00018 #define TRKRECO_DEBUG
00019 #endif
00020 #endif
00021 #define HEP_SHORT_NAMES
00022
00023 #include <string>
00024
00025 class TTrackBase;
00026 class TTrack;
00027
00028 #define TFitAlreadyFitted 1;
00029 #define TFitErrorFewHits -1;
00030 #define TFitFailed -2;
00031 #define TFitUnavailable -3;
00032
00034 class TMFitter {
00035
00036 public:
00038 TMFitter(const std::string & name);
00039
00041 virtual ~TMFitter();
00042
00043 public:
00045 const std::string & name(void) const;
00046 void dump(const std::string & message = std::string(""),
00047 const std::string & prefix = std::string("")) const;
00048
00049 public:
00050 virtual int fit(TTrackBase &) const = 0;
00051
00052 protected:
00054 void fitDone(TTrackBase &) const;
00055
00056 private:
00057 std::string _name;
00058 };
00059
00060
00061
00062 #ifdef TRKRECO_NO_INLINE
00063 #define inline
00064 #else
00065 #undef inline
00066 #define TMFITTER_INLINE_DEFINE_HERE
00067 #endif
00068
00069 #ifdef TMFITTER_INLINE_DEFINE_HERE
00070
00071 inline
00072 const std::string &
00073 TMFitter::name(void) const {
00074 return _name;
00075 }
00076
00077 #endif
00078
00079 #undef inline
00080
00081 #endif