ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/MitProd/TreeFiller/interface/BaseFiller.h
(Generate patch)

Comparing UserCode/MitProd/TreeFiller/interface/BaseFiller.h (file contents):
Revision 1.13 by loizides, Sun Sep 14 15:37:42 2008 UTC vs.
Revision 1.14 by loizides, Sun Mar 15 11:20:40 2009 UTC

# Line 23 | Line 23
23  
24   namespace mithep
25   {
26 +  class BranchTable;
27 +
28    class BaseFiller
29    {
30      public:
31        BaseFiller(const edm::ParameterSet &cfg, const char *name, bool active=true);
32        virtual ~BaseFiller() {}
33  
34 <      bool                     Active()  const { return active_; }
34 >      bool                     Active()  const { return active_;       }
35 >      void                     AddBranchDep(const char *n, const char *d);
36 >      void                     AddBranchDep(const std::string &n, const char *d)
37 >                                 { AddBranchDep(n.c_str(), d);         }
38 >      void                     AddBranchDep(const std::string &n, const std::string &d)
39 >                                 { AddBranchDep(n.c_str(), d.c_str()); }
40        virtual void             BookDataBlock(TreeWriter &tws)                                = 0;
41        virtual void             FillDataBlock(const edm::Event &e, const edm::EventSetup &es) = 0;
42 <      const std::string       &Name()    const { return name_; }
42 >      const std::string       &Name()    const { return name_;         }
43        virtual void             ResolveLinks(const edm::Event &e, const edm::EventSetup &es)    {}
44 <      int                      Verbose() const { return verbose_;}
45 <      bool                     Verify()  const { return verify_;}
44 >      int                      Verbose() const { return verbose_;      }
45 >      bool                     Verify()  const { return verify_;       }
46  
47      protected:
48 <      const edm::ParameterSet &Conf()    const { return config_; }
48 >      const edm::ParameterSet &Conf()    const { return config_;       }
49        void                     PrintErrorAndExit(const char *msg) const;
50        template <typename TYPE>
51        void                     GetProduct(const std::string name, edm::Handle<TYPE> &prod,
# Line 47 | Line 54 | namespace mithep
54        bool                     GetProductSafe(const std::string name, edm::Handle<TYPE> &prod,
55                                                const edm::Event &event) const;    
56  
57 <      ObjectService           *OS() { return FillMitTree::os(); }
57 >      ObjectService           *OS()            { return FillMitTree::os(); }
58  
59        const std::string        name_;    //name of this filler
60 +      const std::string        brtname_; //name of branch table (def = BranchTable)
61        const edm::ParameterSet  config_;  //parameter set for this filler
62        const bool               active_;  //=1 if active
63        const bool               verify_;  //=1 if verificatin code is active
64        const int                verbose_; //verbosity level (do not introduce more than 0-4 levels)
65 +      BranchTable             *brtable_; //branch dependency table
66    };
67   }
68  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines