CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Private Member Functions | Static Private Attributes
l1t::PackerFactory Class Reference

#include <PackerFactory.h>

Public Member Functions

std::shared_ptr< Packermake (const std::string &) const
 

Static Public Member Functions

static const PackerFactoryget ()
 

Private Member Functions

 PackerFactory ()
 

Static Private Attributes

static const PackerFactory instance_
 

Detailed Description

Definition at line 12 of file PackerFactory.h.

Constructor & Destructor Documentation

l1t::PackerFactory::PackerFactory ( )
inlineprivate

Definition at line 18 of file PackerFactory.h.

References instance_.

18 {};

Member Function Documentation

static const PackerFactory* l1t::PackerFactory::get ( )
inlinestatic
std::shared_ptr< Packer > l1t::PackerFactory::make ( const std::string &  name) const

Definition at line 10 of file PackerFactory.cc.

References edm::errors::Configuration, Exception, timingPdfMaker::get, and Skims_PA_cff::name.

Referenced by get(), l1t::stage2::CaloSetup::getPackers(), l1t::stage2::CaloLayer1Setup::getPackers(), l1t::stage2::GMTSetup::getPackers(), l1t::stage2::EMTFSetup::getPackers(), l1t::stage2::BMTFSetup::getPackers(), l1t::stage1::CaloSetup::getPackers(), and l1t::stage2::GTSetup::getPackers().

10  {
11  auto unpacker = std::shared_ptr<Packer>(PackerFactoryT::get()->create("l1t::" + name));
12 
13  if (unpacker.get() == nullptr) {
14  throw edm::Exception(edm::errors::Configuration, "NoSourceModule") << "Cannot find a packer named " << name;
15  }
16 
17  return unpacker;
18  }

Member Data Documentation

const PackerFactory l1t::PackerFactory::instance_
staticprivate

Definition at line 18 of file PackerFactory.h.

Referenced by get(), and PackerFactory().