CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
HGCalProcessorBaseT.h
Go to the documentation of this file.
1 #ifndef __L1Trigger_L1THGCal_HGCalProcessorBaseT_h__
2 #define __L1Trigger_L1THGCal_HGCalProcessorBaseT_h__
3 
6 
8 
9 template <typename InputCollection, typename OutputCollection>
11 public:
13  : geometry_(nullptr), name_(conf.getParameter<std::string>("ProcessorName")) {}
14 
15  virtual ~HGCalProcessorBaseT() {}
16 
17  const std::string& name() const { return name_; }
18 
19  virtual void setGeometry(const HGCalTriggerGeometryBase* const geom) { geometry_ = geom; }
20 
21  virtual void run(const InputCollection& inputColl, OutputCollection& outColl) = 0;
22 
23 protected:
25  if (!geometry_)
26  throw cms::Exception("HGCTriggerSetupError") << "The geometry has not been set in processor " << name_;
27  return geometry_;
28  }
29 
30 private:
33 };
34 
35 #endif
const std::string & name() const
const HGCalTriggerGeometryBase * geometry_
const std::string name_
const HGCalTriggerGeometryBase * geometry() const
HGCalProcessorBaseT(const edm::ParameterSet &conf)
virtual void run(const InputCollection &inputColl, OutputCollection &outColl)=0
virtual void setGeometry(const HGCalTriggerGeometryBase *const geom)