CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_2_9/src/PhysicsTools/RecoAlgos/plugins/MassKinFitterCandCustomProducer.cc

Go to the documentation of this file.
00001 /* \class MassKinFitterCandProducer
00002  *
00003  * \author Luca Lista, INFN
00004  *
00005  */
00006 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00007 #include "PhysicsTools/RecoAlgos/interface/MassKinFitterCandProducer.h"
00008 
00009 class CustomKinFitter : public CandMassKinFitter {
00010 public:
00011   CustomKinFitter(double mass) : CandMassKinFitter(mass) { }
00012 private:
00013   virtual double errEt(double et, double eta) const { return 0.2; }
00014   virtual double errEta(double et, double eta) const { return 0.2; }
00015   virtual double errPhi(double et, double eta) const { return 0.2; }
00016 };
00017 
00018 class MassKinFitterCandCustomProducer : public MassKinFitterCandProducer {
00019 public:
00020   explicit MassKinFitterCandCustomProducer(const edm::ParameterSet& cfg) :
00021     MassKinFitterCandProducer(cfg, new CustomKinFitter(cfg.getParameter<double>("mass"))) { }
00022 };
00023 
00024 #include "FWCore/Framework/interface/MakerMacros.h"
00025 
00026 DEFINE_FWK_MODULE( MassKinFitterCandCustomProducer );
00027