SFrame 3.6
core/include/ISCycleBaseNTuple.h
Go to the documentation of this file.
00001 // Dear emacs, this is -*- c++ -*-
00002 // $Id: ISCycleBaseNTuple.h 283 2011-11-14 18:22:40Z krasznaa $
00003 /***************************************************************************
00004  * @Project: SFrame - ROOT-based analysis framework for ATLAS
00005  * @Package: Core
00006  *
00007  * @author Stefan Ask       <Stefan.Ask@cern.ch>           - Manchester
00008  * @author David Berge      <David.Berge@cern.ch>          - CERN
00009  * @author Johannes Haller  <Johannes.Haller@cern.ch>      - Hamburg
00010  * @author A. Krasznahorkay <Attila.Krasznahorkay@cern.ch> - CERN/Debrecen
00011  *
00012  ***************************************************************************/
00013 
00014 #ifndef SFRAME_CORE_ISCycleBaseNTuple_H
00015 #define SFRAME_CORE_ISCycleBaseNTuple_H
00016 
00017 // STL include(s):
00018 #include <vector>
00019 
00020 // ROOT include(s):
00021 #include <Rtypes.h>
00022 
00023 // Local include(s):
00024 #include "SError.h"
00025 
00026 // Forward declaration(s):
00027 class TTree;
00028 class TList;
00029 class TFile;
00030 class SInputData;
00031 
00044 class ISCycleBaseNTuple {
00045 
00046 public:
00047    virtual ~ISCycleBaseNTuple() {}
00048 
00050    virtual void SetNTupleOutput( TList* output ) = 0;
00052    virtual TList* GetNTupleOutput() const = 0;
00053 
00054 protected:
00056    virtual void CreateOutputTrees( const SInputData& id,
00057                                    std::vector< TTree* >& outTrees,
00058                                    TFile* outputFile = 0 ) throw( SError ) = 0;
00060    virtual void SaveOutputTrees( TDirectory* output ) throw( SError ) = 0;
00062    virtual void LoadInputTrees( const SInputData& id, TTree* main_tree,
00063                                 TFile*& inputFile ) throw( SError ) = 0;
00065    virtual void GetEvent( Long64_t entry ) throw( SError ) = 0;
00067    virtual Double_t CalculateWeight( const SInputData& inputData, Long64_t entry ) = 0;
00069    virtual void ClearCachedTrees() = 0;
00070 
00071 }; // class ISCycleBaseNTuple
00072 
00073 #endif // SFRAME_CORE_ISCycleBaseNTuple_H