ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/MitProd/TreeFiller/interface/BaseFiller.h
Revision: 1.5
Committed: Tue Jun 24 14:25:46 2008 UTC (16 years, 10 months ago) by loizides
Content type: text/plain
Branch: MAIN
Changes since 1.4: +4 -4 lines
Log Message:
Cleanup

File Contents

# Content
1 //--------------------------------------------------------------------------------------------------
2 // $Id: BaseFiller.h,v 1.4 2008/06/20 17:52:57 loizides Exp $
3 //
4 // BaseFiller
5 //
6 // Base class to define the interface for a filler.
7 //
8 // Authors: C.Paus
9 //--------------------------------------------------------------------------------------------------
10
11 #ifndef TREEFILLER_BASEFILLER_H
12 #define TREEFILLER_BASEFILLER_H
13
14 #include "FWCore/Framework/interface/Event.h"
15 #include "FWCore/ParameterSet/interface/ParameterSet.h"
16 #include "FWCore/Framework/interface/Frameworkfwd.h"
17 #include "MitAna/DataUtil/interface/TreeWriter.h"
18
19 namespace mithep
20 {
21 class BaseFiller
22 {
23 public:
24 BaseFiller(const edm::ParameterSet&, const char *name, bool active=true);
25 virtual ~BaseFiller() {}
26
27 bool Active() const { return active_; }
28 virtual void BookDataBlock(TreeWriter &tws) = 0;
29 virtual void FillDataBlock(const edm::Event&, const edm::EventSetup&) = 0;
30 const std::string &Name() const { return name_; }
31 virtual void ResolveLinks(const edm::Event&, const edm::EventSetup&) {}
32
33 protected:
34 const std::string name_; //name of this filler
35 const edm::ParameterSet config_; //parameter set for this filler
36 const bool active_; //=1 if active
37
38 const edm::ParameterSet &Conf() const { return config_; }
39 };
40 }
41 #endif