00001
00002
00003
00004 #ifndef STJTREEREADER_H
00005 #define STJTREEREADER_H
00006
00007 #include <TObject.h>
00008
00009 class TTree;
00010
00011 class StjTreeIndex;
00012
00013 class StjTreeReader : public TObject {
00014
00015 public:
00016 StjTreeReader(TTree* tree) : _tree(tree) { }
00017 StjTreeReader() : _tree(0) { }
00018 virtual ~StjTreeReader() { }
00019
00020 virtual void Init();
00021
00022 virtual Long64_t GetEntryWithIndex(const StjTreeIndex& idx);
00023 virtual Long64_t GetEntryWithIndex(Int_t major, Int_t minor);
00024
00025 protected:
00026
00027 virtual void SetBranchAddress(TTree *tree) { }
00028
00029 virtual void clearEntry() = 0;
00030 virtual void readEntry() = 0;
00031
00032 TTree* _tree;
00033
00034 ClassDef(StjTreeReader, 1)
00035
00036 };
00037
00038 #endif // STJTREEREADER_H