00001 #include "JetMETCorrections/FFTJetObjects/interface/AbsFFTSpecificScaleCalculator.h" 00002 #include "FWCore/ParameterSet/interface/ParameterSet.h" 00003 00004 #include "JetMETCorrections/FFTJetObjects/interface/FFTGenericScaleCalculator.h" 00005 #include "JetMETCorrections/FFTJetObjects/interface/L2AbsScaleCalculator.h" 00006 #include "JetMETCorrections/FFTJetObjects/interface/L2ResScaleCalculator.h" 00007 00008 FFTSpecificScaleCalculatorFactory::FFTSpecificScaleCalculatorFactory() 00009 { 00010 (*this)["L2ResScaleCalculator"] = new ConcreteFFTJetObjectFactory< 00011 AbsFFTSpecificScaleCalculator,L2ResScaleCalculator>(); 00012 00013 (*this)["L2AbsScaleCalculator"] = new ConcreteFFTJetObjectFactory< 00014 AbsFFTSpecificScaleCalculator,L2AbsScaleCalculator>(); 00015 00016 (*this)["FFTGenericScaleCalculator"] = new ConcreteFFTJetObjectFactory< 00017 AbsFFTSpecificScaleCalculator,FFTGenericScaleCalculator>(); 00018 } 00019 00020 AbsFFTSpecificScaleCalculator* parseFFTSpecificScaleCalculator( 00021 const edm::ParameterSet& ps, const std::string& tableDescription) 00022 { 00023 std::string mapper_type(ps.getParameter<std::string>("Class")); 00024 if (!mapper_type.compare("auto")) 00025 mapper_type = tableDescription; 00026 00027 return StaticFFTSpecificScaleCalculatorFactory::instance().create( 00028 mapper_type, ps); 00029 }