00001 #ifndef CAFE_HIST1D_HPP__ 00002 #define CAFE_HIST1D_HPP__ 00003 00004 #include <string> 00005 #include "cafe/Formula.hpp" 00006 #include "cafe/Processor.hpp" 00007 00008 class TFile; 00009 class TH1F; 00010 class TTreeFormula; 00011 class TTreeFormulaManager; 00012 00013 namespace cafe { 00014 00015 class HistoGetter; 00016 00035 class Hist1D : public Processor { 00036 public: 00037 Hist1D(const char *name); 00038 ~Hist1D(); 00039 void begin(); 00040 void inputFileOpened(TFile *file); 00041 bool processEvent(Event& event); 00042 private: 00043 std::string _title; 00044 int _num_bins; 00045 double _bin_min, _bin_max; 00046 TH1F *_hist; 00047 Formula *_select; 00048 Formula *_draw; 00049 TTreeFormulaManager *_mgr; 00050 std::string _weight; 00051 HistoGetter *_getter; 00052 std::string _branch; 00053 std::string _method; 00054 public: 00055 ClassDef(Hist1D, 0); 00056 }; 00057 00058 } 00059 00060 00061 #endif // CAFE_HIST1D_HPP__
1.3.4