CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes
JetCorrectorImplMakerBase Class Reference

#include "JetMETCorrections/Algorithms/interface/JetCorrectorImplMakerBase.h"

Inheritance diagram for JetCorrectorImplMakerBase:
L1FastjetCorrectorImplMaker L1JPTOffsetCorrectorImplMaker L1OffsetCorrectorImplMaker L6SLBCorrectorImplMaker LXXXCorrectorImplMaker

Public Member Functions

 JetCorrectorImplMakerBase (edm::ParameterSet const &)
 
virtual ~JetCorrectorImplMakerBase ()
 

Static Public Member Functions

static void addToDescription (edm::ParameterSetDescription &iDescription)
 

Protected Member Functions

std::shared_ptr< FactorizedJetCorrectorCalculator const > getCalculator (edm::EventSetup const &, std::function< void(std::string const &)> levelCheck)
 

Private Member Functions

 JetCorrectorImplMakerBase (const JetCorrectorImplMakerBase &)=delete
 
const JetCorrectorImplMakerBaseoperator= (const JetCorrectorImplMakerBase &)=delete
 

Private Attributes

std::string algo_
 
unsigned long long cacheId_
 
std::shared_ptr< FactorizedJetCorrectorCalculator const > corrector_
 
std::string level_
 

Detailed Description

Description: [one line class summary]

Usage: <usage>

Definition at line 36 of file JetCorrectorImplMakerBase.h.

Constructor & Destructor Documentation

◆ JetCorrectorImplMakerBase() [1/2]

JetCorrectorImplMakerBase::JetCorrectorImplMakerBase ( edm::ParameterSet const &  iPSet)

Definition at line 38 of file JetCorrectorImplMakerBase.cc.

39  : level_(iPSet.getParameter<std::string>("level")),
40  algo_(iPSet.getParameter<std::string>("algorithm")),
41  cacheId_(0) {}

◆ ~JetCorrectorImplMakerBase()

JetCorrectorImplMakerBase::~JetCorrectorImplMakerBase ( )
virtual

Definition at line 48 of file JetCorrectorImplMakerBase.cc.

48 {}

◆ JetCorrectorImplMakerBase() [2/2]

JetCorrectorImplMakerBase::JetCorrectorImplMakerBase ( const JetCorrectorImplMakerBase )
privatedelete

Member Function Documentation

◆ addToDescription()

void JetCorrectorImplMakerBase::addToDescription ( edm::ParameterSetDescription iDescription)
static

◆ getCalculator()

std::shared_ptr< FactorizedJetCorrectorCalculator const > JetCorrectorImplMakerBase::getCalculator ( edm::EventSetup const &  iSetup,
std::function< void(std::string const &)>  levelCheck 
)
protected

Definition at line 54 of file JetCorrectorImplMakerBase.cc.

55  {
56  auto const& rec = iSetup.get<JetCorrectionsRecord>();
57  if (cacheId_ != rec.cacheIdentifier()) {
59  rec.get(algo_, JetCorParColl);
60  auto const& parameters = ((*JetCorParColl)[level_]);
61 
62  iLevelCheck(parameters.definitions().level());
63  std::vector<JetCorrectorParameters> vParam;
64  vParam.push_back(parameters);
65  corrector_ = std::make_shared<FactorizedJetCorrectorCalculator>(vParam);
66 
67  cacheId_ = rec.cacheIdentifier();
68  }
69  return corrector_;
70 }

References algo_, cacheId_, corrector_, edm::EventSetup::get(), and level_.

Referenced by LXXXCorrectorImplMaker::make(), L1OffsetCorrectorImplMaker::make(), L1FastjetCorrectorImplMaker::make(), L1JPTOffsetCorrectorImplMaker::make(), and L6SLBCorrectorImplMaker::make().

◆ operator=()

const JetCorrectorImplMakerBase& JetCorrectorImplMakerBase::operator= ( const JetCorrectorImplMakerBase )
privatedelete

Member Data Documentation

◆ algo_

std::string JetCorrectorImplMakerBase::algo_
private

Definition at line 59 of file JetCorrectorImplMakerBase.h.

Referenced by getCalculator().

◆ cacheId_

unsigned long long JetCorrectorImplMakerBase::cacheId_
private

Definition at line 61 of file JetCorrectorImplMakerBase.h.

Referenced by getCalculator().

◆ corrector_

std::shared_ptr<FactorizedJetCorrectorCalculator const> JetCorrectorImplMakerBase::corrector_
private

Definition at line 60 of file JetCorrectorImplMakerBase.h.

Referenced by getCalculator().

◆ level_

std::string JetCorrectorImplMakerBase::level_
private

Definition at line 58 of file JetCorrectorImplMakerBase.h.

Referenced by getCalculator().

BeamSpotPI::parameters
parameters
Definition: BeamSpotPayloadInspectorHelper.h:30
edm::ParameterSetDescription::add
ParameterDescriptionBase * add(U const &iLabel, T const &value)
Definition: ParameterSetDescription.h:95
JetCorrectorImplMakerBase::corrector_
std::shared_ptr< FactorizedJetCorrectorCalculator const > corrector_
Definition: JetCorrectorImplMakerBase.h:60
edm::ESHandle
Definition: DTSurvey.h:22
JetCorrectionsRecord
Definition: JetCorrectionsRecord.h:11
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
JetCorrectorImplMakerBase::cacheId_
unsigned long long cacheId_
Definition: JetCorrectorImplMakerBase.h:61
JetCorrectorImplMakerBase::algo_
std::string algo_
Definition: JetCorrectorImplMakerBase.h:59
JetCorrectorImplMakerBase::level_
std::string level_
Definition: JetCorrectorImplMakerBase.h:58