CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Private Member Functions
edm::service::LoadAllDictionaries Class Reference

Public Member Functions

 LoadAllDictionaries (const edm::ParameterSet &)
 

Static Public Member Functions

static void fillDescriptions (edm::ConfigurationDescriptions &descriptions)
 

Private Member Functions

 LoadAllDictionaries (const LoadAllDictionaries &)=delete
 
const LoadAllDictionariesoperator= (const LoadAllDictionaries &)=delete
 

Detailed Description

Definition at line 32 of file LoadAllDictionaries.cc.

Constructor & Destructor Documentation

LoadAllDictionaries::LoadAllDictionaries ( const edm::ParameterSet iConfig)

Definition at line 65 of file LoadAllDictionaries.cc.

References edmplugin::PluginManager::categoryToInfos(), edmplugin::PluginCapabilities::get(), edmplugin::PluginManager::get(), edm::ParameterSet::getUntrackedParameter(), edmplugin::PluginCapabilities::load(), and AlCaHLTBitMon_QueryRunRegistry::string.

65  {
66  bool doLoad(iConfig.getUntrackedParameter<bool>("doLoad"));
67  if (doLoad) {
69 
71 
72  CatToInfos::const_iterator itFound = db->categoryToInfos().find("Capability");
73 
74  if (itFound == db->categoryToInfos().end()) {
75  return;
76  }
77  std::string lastClass;
78  const std::string mystring("edm::Wrapper");
79 
80  for (edmplugin::PluginManager::Infos::const_iterator itInfo = itFound->second.begin(),
81  itInfoEnd = itFound->second.end();
82  itInfo != itInfoEnd;
83  ++itInfo) {
84  if (lastClass == itInfo->name_) {
85  continue;
86  }
87 
88  lastClass = itInfo->name_;
89  if (lastClass.find(mystring) != std::string::npos) {
91  }
92  //NOTE: since we have the library already, we could be more efficient if we just load it ourselves
93  }
94  }
95 }
const CategoryToInfos & categoryToInfos() const
Definition: PluginManager.h:83
T getUntrackedParameter(std::string const &, T const &) const
std::map< std::string, Infos > CategoryToInfos
Definition: PluginManager.h:54
static PluginCapabilities * get()
void load(const std::string &iName)
static PluginManager * get()
edm::service::LoadAllDictionaries::LoadAllDictionaries ( const LoadAllDictionaries )
privatedelete

Member Function Documentation

void LoadAllDictionaries::fillDescriptions ( edm::ConfigurationDescriptions descriptions)
static

Definition at line 97 of file LoadAllDictionaries.cc.

References edm::ConfigurationDescriptions::add(), edm::ParameterSetDescription::addUntracked(), and edm::ConfigurationDescriptions::setComment().

97  {
99  desc.addUntracked<bool>("doLoad", true)->setComment("Only if 'true' do we load all dictionaries");
100  descriptions.add("LoadAllDictionaries", desc);
101  descriptions.setComment(
102  "This service allows you to force all known dictionaries to be loaded at the beginning of the job");
103 }
ParameterDescriptionBase * addUntracked(U const &iLabel, T const &value)
void setComment(std::string const &value)
void add(std::string const &label, ParameterSetDescription const &psetDescription)
const LoadAllDictionaries& edm::service::LoadAllDictionaries::operator= ( const LoadAllDictionaries )
privatedelete