00001 // $Id: TGo4MbsHist.h 478 2009-10-29 12:26:09Z linev $ 00002 //----------------------------------------------------------------------- 00003 // The GSI Online Offline Object Oriented (Go4) Project 00004 // Experiment Data Processing at EE department, GSI 00005 //----------------------------------------------------------------------- 00006 // Copyright (C) 2000- GSI Helmholtzzentrum für Schwerionenforschung GmbH 00007 // Planckstr. 1, 64291 Darmstadt, Germany 00008 // Contact: http://go4.gsi.de 00009 //----------------------------------------------------------------------- 00010 // This software can be used under the license agreements as stated 00011 // in Go4License.txt file which is part of the distribution. 00012 //----------------------------------------------------------------------- 00013 00014 #ifndef TGO4MBSHIST_H 00015 #define TGO4MBSHIST_H 00016 00017 #include "TObject.h" 00018 #include "Htypes.h" 00019 00020 extern "C" 00021 { 00022 #include "s_his_head.h" 00023 } 00024 00025 class TFolder; 00026 class TH1; 00027 00032 class TGo4MbsHist : public TObject { 00033 public: 00034 00035 TGo4MbsHist(); 00036 00040 TGo4MbsHist(TH1* histo); 00041 00045 TGo4MbsHist(TFolder* histofolder, const char* filter=0); 00046 00047 virtual ~TGo4MbsHist(); 00048 00049 s_his_head* GetHead() { return &fxHistoHead; } 00050 Int_t* GetBuffer() { return fiBuffer; } 00051 Int_t GetBufLen() const { return fiBufLen; } 00052 Int_t GetHisNum() const { return fiHisNum; } 00053 00055 static const Int_t fgiLISTLEN; 00056 00057 private: 00058 00060 void PrepareHeader(TH1* source, const char* path, s_his_head* target); 00061 00064 void ScanGo4Folder(TFolder* fold, const char* superfolders=0, const char* filter=0); 00065 00068 void SetValue(char* address, Stat_t value); 00069 00070 s_his_head fxHistoHead; 00071 Int_t fiBufLen; 00072 Int_t* fiBuffer; 00073 00074 /* Points to next histogram header in buffer in case of nameslist */ 00075 s_his_head* fxCursor; 00076 00078 Int_t fiHisNum; 00079 }; 00080 00081 #endif //TGO4MBSHIST_H