00001 //-------------------------------------------------------------------------- 00002 // File and Version Information: 00003 // $Id: TrkHistory.h,v 1.1.1.1 2005/04/21 06:01:42 zhangy Exp $ 00004 // 00005 // Description: TrkHistory; simple class to record the history 00006 // of a track fit 00007 // 00008 // Environment: 00009 // Software developed for the BaBar Detector at the SLAC B-Factory. 00010 // 00011 // Author(s): Dave Brown 00012 // 00013 //------------------------------------------------------------------------ 00014 00015 #ifndef TRKHISTORY_HH 00016 #define TRKHISTORY_HH 00017 00018 #include "TrkBase/TrkErrCode.h" 00019 #include <iostream> 00020 00021 class TrkHistory { 00022 public: 00023 TrkHistory(); 00024 TrkHistory(const TrkErrCode& err,const char* modname); 00025 TrkHistory(const TrkHistory& other); 00026 TrkHistory& operator =(const TrkHistory& other); 00027 ~TrkHistory(); 00028 // accessors 00029 const TrkErrCode& status() const { return _err; } 00030 const char* module() const { return _mod; } 00031 bool operator == (const TrkHistory& other) const; 00032 void print(std::ostream& os=std::cout) const; 00033 private: 00034 TrkErrCode _err; 00035 const char* _mod; 00036 }; 00037 // stream operator 00038 std::ostream& operator<<(std::ostream& os, const TrkHistory& history); 00039 00040 #endif 00041