CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
LoadAllDictionaries.cc
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Package: Services
4 // Class : LoadAllDictionaries
5 //
6 // Implementation:
7 // <Notes on implementation>
8 //
9 // Original Author: Chris Jones
10 // Created: Thu Sep 15 09:47:48 EDT 2005
11 //
12 
13 // system include files
14 #include "Cintex/Cintex.h"
15 
16 // user include files
23 
24 //
25 // constants, enums and typedefs
26 //
27 
28 //
29 // static data member definitions
30 //
31 
32 //
33 // constructors and destructor
34 //
36 {
37  bool doLoad(iConfig.getUntrackedParameter<bool>("doLoad"));
38  if(doLoad) {
39  ROOT::Cintex::Cintex::Enable();
40 
42 
44 
45  CatToInfos::const_iterator itFound = db->categoryToInfos().find("Capability");
46 
47  if(itFound == db->categoryToInfos().end()) {
48  return;
49  }
50  std::string lastClass;
51  const std::string mystring("edm::Wrapper");
52 
53  for (edmplugin::PluginManager::Infos::const_iterator itInfo = itFound->second.begin(),
54  itInfoEnd = itFound->second.end();
55  itInfo != itInfoEnd; ++itInfo)
56  {
57  if (lastClass == itInfo->name_) {
58  continue;
59  }
60 
61  lastClass = itInfo->name_;
62  if (lastClass.find(mystring) != std::string::npos) {
64  }
65  //NOTE: since we have the library already, we could be more efficient if we just load it ourselves
66  }
67  }
68 }
69 
72  desc.addUntracked<bool>("doLoad", true)->setComment("Only if 'true' do we load all dictionaries");
73  descriptions.add("LoadAllDictionaries", desc);
74  descriptions.setComment("This service allows you to force all known dictionaries to be loaded at the beginning of the job");
75 }
76 
const CategoryToInfos & categoryToInfos() const
Definition: PluginManager.h:82
T getUntrackedParameter(std::string const &, T const &) const
ParameterDescriptionBase * addUntracked(U const &iLabel, T const &value)
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
tuple db
Definition: EcalCondDB.py:151
std::map< std::string, Infos > CategoryToInfos
Definition: PluginManager.h:54
static PluginCapabilities * get()
void setComment(std::string const &value)
void add(std::string const &label, ParameterSetDescription const &psetDescription)
void load(const std::string &iName)
LoadAllDictionaries(const edm::ParameterSet &)
static PluginManager * get()