CMS 3D CMS Logo

PackingSetupFactory.cc
Go to the documentation of this file.
1 #include "PackingSetupFactory.h"
2 
4 
6 
7 namespace l1t {
8  const PackingSetupFactory PackingSetupFactory::instance_;
9 
10  std::unique_ptr<PackingSetup>
12  {
13  auto helper = std::unique_ptr<PackingSetup>(PackingSetupFactoryT::get()->create("l1t::" + type));
14 
15  if (helper.get() == nullptr)
16  throw edm::Exception(edm::errors::Configuration, "NoSourceModule") << "cannot find packing setup " << type;
17 
18  return helper;
19  }
20 
21  void
23  {
24  for (const auto& info: PackingSetupFactoryT::get()->available()) {
25  PackingSetupFactoryT::get()->create(info.name_)->fillDescription(desc);
26  }
27  }
28 }
type
Definition: HCALResponse.h:21
static const TGPicture * info(bool iBackgroundIsBlack)
Definition: helper.py:1
static const PackingSetupFactory instance_
delete x;
Definition: CaloConfig.h:22
void fillDescription(edm::ParameterSetDescription &) const
std::unique_ptr< PackingSetup > make(const std::string &) const
#define EDM_REGISTER_PLUGINFACTORY(_factory_, _category_)
Definition: PluginFactory.h:91
T get(const Candidate &c)
Definition: component.h:55