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 // $Id: LoadAllDictionaries.cc,v 1.10 2010/07/20 22:13:22 chrjones Exp $
12 //
13 
14 // system include files
15 #include "Cintex/Cintex.h"
16 
17 // user include files
24 
25 //
26 // constants, enums and typedefs
27 //
28 
29 //
30 // static data member definitions
31 //
32 
33 //
34 // constructors and destructor
35 //
37 {
38  bool doLoad(iConfig.getUntrackedParameter<bool>("doLoad"));
39  if(doLoad) {
40  ROOT::Cintex::Cintex::Enable();
41 
43 
45 
46  CatToInfos::const_iterator itFound = db->categoryToInfos().find("Capability");
47 
48  if(itFound == db->categoryToInfos().end()) {
49  return;
50  }
51  std::string lastClass;
52  const std::string cPrefix("LCGReflex/");
53  const std::string mystring("edm::Wrapper");
54 
55  for (edmplugin::PluginManager::Infos::const_iterator itInfo = itFound->second.begin(),
56  itInfoEnd = itFound->second.end();
57  itInfo != itInfoEnd; ++itInfo)
58  {
59  if (lastClass == itInfo->name_) {
60  continue;
61  }
62 
63  lastClass = itInfo->name_;
64  if (lastClass.find(mystring) != std::string::npos) {
66  }
67  //NOTE: since we have the library already, we could be more efficient if we just load it ourselves
68  }
69  }
70 }
71 
74  desc.addUntracked<bool>("doLoad", true)->setComment("Only if 'true' do we load all dictionaries");
75  descriptions.add("LoadAllDictionaries", desc);
76  descriptions.setComment("This service allows you to force all known Reflex dictionaries to be loaded at the beginning of the job");
77 }
78 
const CategoryToInfos & categoryToInfos() const
Definition: PluginManager.h:71
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:43
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()