CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ProductHolderIndexHelper.cc
Go to the documentation of this file.
1 
9 
10 #include <TClass.h>
11 
12 #include <cassert>
13 #include <iostream>
14 #include <limits>
15 
16 namespace edm {
17 
18  namespace productholderindexhelper {
19  TypeID
20  getContainedTypeFromWrapper(TypeID const& wrappedTypeID, std::string const& className) {
21  static int const vtcOffset = TClass::GetClass("edm::WrapperBase")->GetBaseClassOffset(TClass::GetClass("edm::ViewTypeChecker"));
22  static TClass const* const wbClass = TClass::GetClass("edm::WrapperBase");
23  static std::string const refVector("edm::RefVector<");
24  static std::string const refToBaseVector("edm::RefToBaseVector<");
25  static std::string const ptrVector("edm::PtrVector<");
26  static std::string const vectorPtr("std::vector<edm::Ptr<");
27  static size_t const rvsize = refVector.size();
28  static size_t const rtbvsize = refToBaseVector.size();
29  static size_t const pvsize = ptrVector.size();
30  static size_t const vpsize = vectorPtr.size();
31  bool mayBeRefVector = (className.substr(0, rvsize) == refVector)
32  || (className.substr(0, rtbvsize) == refToBaseVector)
33  || (className.substr(0, pvsize) == ptrVector)
34  || (className.substr(0, vpsize) == vectorPtr);
35  TClass* cl = TClass::GetClass(wrappedTypeID.className().c_str());
36  if(cl == nullptr) {
37  return TypeID(typeid(void));
38  }
39  void* p = cl->New();
40  int offset = cl->GetBaseClassOffset(wbClass) + vtcOffset;;
41  std::unique_ptr<ViewTypeChecker> checker = getAnyPtr<ViewTypeChecker>(p, offset);
42  if(mayBeRefVector) {
43  std::type_info const& ti = checker->memberTypeInfo();
44  if(ti != typeid(void)) {
45  return TypeID(ti);
46  }
47  }
48  return TypeID(checker->valueTypeInfo());
49  }
50 
51  TypeID
52  getContainedType(TypeID const& typeID) {
53  std::string className = typeID.className();
54  TypeWithDict const wrappedType = TypeWithDict::byName(wrappedClassName(className));
55  TypeID const wrappedTypeID = TypeID(wrappedType.typeInfo());
56  return getContainedTypeFromWrapper(wrappedTypeID, className);
57  }
58  }
59 
61  nextIndexValue_(0),
62  beginElements_(0),
63  items_(new std::set<ProductHolderIndexHelper::Item>),
64  processItems_(new std::set<std::string>) {
65  }
66 
69  TypeID const& typeID,
70  char const* moduleLabel,
71  char const* instance,
72  char const* process) const {
73 
74  unsigned int iToIndexAndNames = indexToIndexAndNames(kindOfType,
75  typeID,
76  moduleLabel,
77  instance,
78  process);
79 
80  if (iToIndexAndNames == std::numeric_limits<unsigned int>::max()) {
82  }
83  return indexAndNames_[iToIndexAndNames].index();
84  }
85 
87  unsigned int startInIndexAndNames,
88  unsigned int numberOfMatches) :
89  productHolderIndexHelper_(productHolderIndexHelper),
90  startInIndexAndNames_(startInIndexAndNames),
91  numberOfMatches_(numberOfMatches) {
92  if (numberOfMatches != 0 && startInIndexAndNames_ + numberOfMatches_ > productHolderIndexHelper_->indexAndNames_.size()) {
94  << "ProductHolderIndexHelper::Matches::Matches - Arguments exceed vector bounds.\n";
95  }
96  }
97 
100  if (i >= numberOfMatches_) {
102  << "ProductHolderIndexHelper::Matches::index - Argument is out of range.\n";
103  }
104  return productHolderIndexHelper_->indexAndNames_[startInIndexAndNames_ + i].index();
105  }
106 
107  bool
109  if (i >= numberOfMatches_) {
111  << "ProductHolderIndexHelper::Matches::isFullyResolved - Argument is out of range.\n";
112  }
113  return (productHolderIndexHelper_->indexAndNames_[startInIndexAndNames_ + i].startInProcessNames() != 0U);
114  }
115 
116  char const*
118  if (i >= numberOfMatches_) {
120  << "ProductHolderIndexHelper::Matches::processName - Argument is out of range.\n";
121  }
122  unsigned int startInProcessNames = productHolderIndexHelper_->indexAndNames_[startInIndexAndNames_ + i].startInProcessNames();
123  return &productHolderIndexHelper_->processNames_[startInProcessNames];
124  }
125 
126  char const*
128  if (i >= numberOfMatches_) {
130  << "ProductHolderIndexHelper::Matches::moduleLabel - Argument is out of range.\n";
131  }
132  unsigned int start = productHolderIndexHelper_->indexAndNames_[startInIndexAndNames_ + i].startInBigNamesContainer();
133  return &productHolderIndexHelper_->bigNamesContainer_[start];
134  }
135 
138  TypeID const& typeID,
139  char const* moduleLabel,
140  char const* instance) const {
141 
142  unsigned int startInIndexAndNames = indexToIndexAndNames(kindOfType,
143  typeID,
144  moduleLabel,
145  instance,
146  0);
147  unsigned int numberOfMatches = 1;
148 
149  if (startInIndexAndNames == std::numeric_limits<unsigned int>::max()) {
150  numberOfMatches = 0;
151  } else {
152  auto vSize = indexAndNames_.size();
153  for (unsigned int j = startInIndexAndNames + 1U;
154  j < vSize && (indexAndNames_[j].startInProcessNames() != 0U);
155  ++j) {
156  ++numberOfMatches;
157  }
158  }
159  return Matches(this, startInIndexAndNames, numberOfMatches);
160  }
161 
164  TypeID const& typeID) const {
165 
166  unsigned int startInIndexAndNames = std::numeric_limits<unsigned int>::max();
167  unsigned int numberOfMatches = 0;
168 
169  // Look for the type and check to see if it found it
170  unsigned iType = indexToType(kindOfType, typeID);
172 
173  // Get the range of entries with a matching TypeID
174  Range const& range = ranges_[iType];
175 
176  startInIndexAndNames = range.begin();
177  numberOfMatches = range.end() - range.begin();
178  }
179  return Matches(this, startInIndexAndNames, numberOfMatches);
180  }
181 
184  char const* moduleLabel,
185  char const* instance,
186  char const* process,
187  TypeID const& containedTypeID) {
188  if (!items_) {
190  << "ProductHolderIndexHelper::insert - Attempt to insert more elements after frozen.\n";
191  }
192 
193  if (process == 0 || *process == '\0') {
195  << "ProductHolderIndexHelper::insert - Empty process.\n";
196  }
197 
198  // Throw if this has already been inserted
199  Item item(PRODUCT_TYPE, typeID, moduleLabel, instance, process, 0);
200  std::set<Item>::iterator iter = items_->find(item);
201  if (iter != items_->end()) {
203  << "ProductHolderIndexHelper::insert - Attempt to insert duplicate entry.\n";
204  }
205 
206  // Put in an entry for the product
208  unsigned int savedProductIndex = nextIndexValue_;
209  ++nextIndexValue_;
210  items_->insert(item);
211 
212  // Put in an entry for the product with an empty process name
213  // if it is not already there
214  item.clearProcess();
215  iter = items_->find(item);
216  if (iter == items_->end()) {
218  ++nextIndexValue_;
219  items_->insert(item);
220  }
221 
222  // Now put in entries for a contained class if this is a
223  // recognized container.
224  if(containedTypeID != TypeID(typeid(void)) && containedTypeID != TypeID()) {
225  TypeWithDict containedType(containedTypeID.typeInfo());
226 
227  Item containedItem(ELEMENT_TYPE, containedTypeID, moduleLabel, instance, process, savedProductIndex);
228  iter = items_->find(containedItem);
229  if (iter != items_->end()) {
230  containedItem.setIndex(ProductHolderIndexAmbiguous);
231  items_->erase(iter);
232  }
233  items_->insert(containedItem);
234 
235  containedItem.clearProcess();
236  iter = items_->find(containedItem);
237  if (iter == items_->end()) {
238  containedItem.setIndex(nextIndexValue_);
239  ++nextIndexValue_;
240  items_->insert(containedItem);
241  }
242 
243  // Repeat this for all public base classes of the contained type
244  std::vector<TypeWithDict> baseTypes;
245  public_base_classes(containedType, baseTypes);
246 
247  for(TypeWithDict const& baseType : baseTypes) {
248 
249  TypeID baseTypeID(baseType.typeInfo());
250  Item baseItem(ELEMENT_TYPE, baseTypeID, moduleLabel, instance, process, savedProductIndex);
251  iter = items_->find(baseItem);
252  if (iter != items_->end()) {
253  baseItem.setIndex(ProductHolderIndexAmbiguous);
254  items_->erase(iter);
255  }
256  items_->insert(baseItem);
257 
258  baseItem.clearProcess();
259  iter = items_->find(baseItem);
260  if (iter == items_->end()) {
261  baseItem.setIndex(nextIndexValue_);
262  ++nextIndexValue_;
263  items_->insert(baseItem);
264  }
265  }
266  }
267  return savedProductIndex;
268  }
269 
271 
272  if (!items_) return;
273 
274  // Make a first pass and count things so we
275  // can reserve memory in the vectors. Also
276  // fill processItems_ on the first pass.
277  bool iFirstThisType = true;
278  bool beginElementsWasSet = false;
279  TypeID previousTypeID;
280  KindOfType previousKindOfType = PRODUCT_TYPE;
281  std::string previousModuleLabel;
282  std::string previousInstance;
283  unsigned int iCountTypes = 0;
284  unsigned int iCountCharacters = 0;
285  for (auto const& item : *items_) {
286 
287  if (iFirstThisType || item.typeID() != previousTypeID || item.kindOfType() != previousKindOfType) {
288  ++iCountTypes;
289  iFirstThisType = true;
290 
291  if (!beginElementsWasSet) {
292  if (item.kindOfType() == ELEMENT_TYPE) {
293  beginElementsWasSet = true;
294  } else {
295  beginElements_ = iCountTypes;
296  }
297  }
298  }
299 
300  processItems_->insert(item.process());
301 
302  if (iFirstThisType ||
303  item.moduleLabel() != previousModuleLabel ||
304  item.instance() != previousInstance) {
305  iCountCharacters += item.moduleLabel().size();
306  iCountCharacters += item.instance().size();
307  iCountCharacters += 2;
308  }
309 
310  iFirstThisType = false;
311  previousTypeID = item.typeID();
312  previousKindOfType = item.kindOfType();
313  previousModuleLabel = item.moduleLabel();
314  previousInstance = item.instance();
315  }
316 
317  // Size and fill the process name vector
318  unsigned int processNamesSize = 0;
319  for (auto const& processItem : *processItems_) {
320  processNamesSize += processItem.size();
321  ++processNamesSize;
322  }
323  processNames_.reserve(processNamesSize);
324  for (auto const& processItem : *processItems_) {
325  for (auto const& c : processItem) {
326  processNames_.push_back(c);
327  }
328  processNames_.push_back('\0');
329  lookupProcessNames_.push_back(processItem);
330  }
331 
332  // Reserve memory in the vectors
333  sortedTypeIDs_.reserve(iCountTypes);
334  ranges_.reserve(iCountTypes);
335  indexAndNames_.reserve(items_->size());
336  bigNamesContainer_.reserve(iCountCharacters);
337 
338  // Second pass. Really fill the vectors this time.
339  bool iFirstType = true;
340  iFirstThisType = true;
341  previousTypeID = TypeID();
342  unsigned int iCount = 0;
343  unsigned int iBeginning = 0;
344  iCountCharacters = 0;
345  unsigned int previousCharacterCount = 0;
346  if (!items_->empty()) {
347  for (auto const& item : *items_) {
348 
349  if (iFirstThisType || item.typeID() != previousTypeID || item.kindOfType() != previousKindOfType) {
350  iFirstThisType = true;
351  sortedTypeIDs_.push_back(item.typeID());
352  if (iFirstType) {
353  iFirstType = false;
354  } else {
355  ranges_.push_back(Range(iBeginning, iCount));
356  }
357  iBeginning = iCount;
358  }
359  ++iCount;
360 
361  if (iFirstThisType ||
362  item.moduleLabel() != previousModuleLabel ||
363  item.instance() != previousInstance) {
364 
365  unsigned int labelSize = item.moduleLabel().size();
366  for (unsigned int j = 0; j < labelSize; ++j) {
367  bigNamesContainer_.push_back(item.moduleLabel()[j]);
368  }
369  bigNamesContainer_.push_back('\0');
370 
371  unsigned int instanceSize = item.instance().size();
372  for (unsigned int j = 0; j < instanceSize; ++j) {
373  bigNamesContainer_.push_back(item.instance()[j]);
374  }
375  bigNamesContainer_.push_back('\0');
376 
377  previousCharacterCount = iCountCharacters;
378 
379  iCountCharacters += labelSize;
380  iCountCharacters += instanceSize;
381  iCountCharacters += 2;
382  }
383 
384  unsigned int processStart = processIndex(item.process().c_str());
385  if (processStart == std::numeric_limits<unsigned int>::max()) {
387  << "ProductHolderIndexHelper::setFrozen - Process not found in processNames_.\n";
388  }
389  indexAndNames_.emplace_back(item.index(), previousCharacterCount, processStart);
390 
391  iFirstThisType = false;
392  previousTypeID = item.typeID();
393  previousKindOfType = item.kindOfType();
394  previousModuleLabel = item.moduleLabel();
395  previousInstance = item.instance();
396  }
397  ranges_.push_back(Range(iBeginning, iCount));
398  }
399 
400  // Some sanity checks to protect against out of bounds vector accesses
401  // These should only fail if there is a bug. If profiling ever shows
402  // them to be expensive one might delete them.
403  sanityCheck();
404 
405  // Cleanup, do not need the temporary containers anymore
406  // propagate_const<T> has no reset() function
407  items_ = nullptr;
408  processItems_ = nullptr;
409  }
410 
411  std::vector<std::string> const& ProductHolderIndexHelper::lookupProcessNames() const {
412  if (items_) {
414  << "ProductHolderIndexHelper::lookupProcessNames - Attempt to access names before frozen.\n";
415  }
416  return lookupProcessNames_;
417  }
418 
419  unsigned int
421  TypeID const& typeID,
422  char const* moduleLabel,
423  char const* instance,
424  char const* process) const {
425 
426  // Look for the type and check to see if it found it
427  unsigned iType = indexToType(kindOfType, typeID);
429 
430  unsigned startProcess = 0;
431  if (process) {
432  startProcess = processIndex(process);
433  if (startProcess == std::numeric_limits<unsigned int>::max()) {
435  }
436  }
437 
438  ProductHolderIndexHelper::Range const& range = ranges_[iType];
439  unsigned int begin = range.begin();
440  unsigned int end = range.end();
441 
442  while (begin < end) {
443 
444  unsigned int midpoint = begin + ((end - begin) / 2);
445  char const* namePtr = &bigNamesContainer_[indexAndNames_[midpoint].startInBigNamesContainer()];
446 
447  // Compare the module label
448  char const* label = moduleLabel;
449  while (*namePtr && (*namePtr == *label)) {
450  ++namePtr; ++label;
451  }
452  if (*namePtr == *label) { // true only if both are at the '\0' at the end of the C string
453  ++namePtr; // move to the next C string
454 
455  // Compare the instance name
456  char const* instanceName = instance;
457  while (*namePtr && (*namePtr == *instanceName)) {
458  ++namePtr; ++instanceName;
459  }
460  if (*namePtr == *instanceName) {
461 
462  // Compare the process name
463  if (startProcess == indexAndNames_[midpoint].startInProcessNames()) {
464  return midpoint;
465  } else {
466  if (indexAndNames_[midpoint].startInProcessNames() > startProcess) {
467  while (true) {
468  --midpoint;
469  if (indexAndNames_[midpoint].startInProcessNames() == startProcess) {
470  return midpoint;
471  }
472  if (indexAndNames_[midpoint].startInProcessNames() == 0) break;
473  }
474  } else {
475  while (true) {
476  ++midpoint;
477  if (midpoint == indexAndNames_.size()) break;
478  if (indexAndNames_[midpoint].startInProcessNames() == 0) break;
479  if (indexAndNames_[midpoint].startInProcessNames() == startProcess) {
480  return midpoint;
481  }
482  }
483  }
484  break;
485  }
486  } else if (*namePtr < *instanceName) {
487  if (begin == midpoint) break;
488  begin = midpoint;
489  } else {
490  end = midpoint;
491  }
492  } else if (*namePtr < *label) {
493  if (begin == midpoint) break;
494  begin = midpoint;
495  } else {
496  end = midpoint;
497  }
498  } // end while (begin < end)
499  }
501  }
502 
503  unsigned int
505  TypeID const& typeID) const {
506 
507  unsigned int beginType = 0;
508  unsigned int endType = beginElements_;
509  if (kindOfType == ELEMENT_TYPE) {
510  beginType = beginElements_;
511  endType = sortedTypeIDs_.size();
512  }
513 
514  while (beginType < endType) {
515  unsigned int midpointType = beginType + ((endType - beginType) / 2);
516  if (sortedTypeIDs_[midpointType] == typeID) {
517  return midpointType; // Found it
518  } else if (sortedTypeIDs_[midpointType] < typeID) {
519  if (beginType == midpointType) break;
520  beginType = midpointType;
521  } else {
522  endType = midpointType;
523  }
524  }
525  return std::numeric_limits<unsigned int>::max(); // Failed to find it
526  }
527 
528  unsigned int ProductHolderIndexHelper::processIndex(char const* process) const {
529 
530  char const* ptr = &processNames_[0];
531  char const* begin = ptr;
532  while (true) {
533  char const* p = process;
534  char const* beginName = ptr;
535  while (*ptr && (*ptr == *p)) {
536  ++ptr; ++p;
537  }
538  if (*ptr == *p) {
539  return beginName - begin;
540  }
541  while (*ptr) {
542  ++ptr;
543  }
544  ++ptr;
545  if (static_cast<unsigned>(ptr - begin) >= processNames_.size()) {
547  }
548  }
549  return 0;
550  }
551 
553  bool sanityChecksPass = true;
554  if (sortedTypeIDs_.size() != ranges_.size()) sanityChecksPass = false;
555 
556  unsigned int previousEnd = 0;
557  for ( auto const& range : ranges_) {
558  if (range.begin() != previousEnd) sanityChecksPass = false;
559  if (range.begin() >= range.end()) sanityChecksPass = false;
560  previousEnd = range.end();
561  }
562  if (previousEnd != indexAndNames_.size()) sanityChecksPass = false;
563 
564 
565  unsigned maxStart = 0;
566  unsigned maxStartProcess = 0;
567  for (auto const& indexAndName : indexAndNames_) {
568  if (indexAndName.index() >= nextIndexValue_ && indexAndName.index() != ProductHolderIndexAmbiguous) sanityChecksPass = false;
569 
570  if (indexAndName.startInBigNamesContainer() >= bigNamesContainer_.size()) sanityChecksPass = false;
571  if (indexAndName.startInProcessNames() >= processNames_.size()) sanityChecksPass = false;
572 
573  if (indexAndName.startInBigNamesContainer() > maxStart) maxStart = indexAndName.startInBigNamesContainer();
574  if (indexAndName.startInProcessNames() > maxStartProcess) maxStartProcess = indexAndName.startInProcessNames();
575  }
576 
577  if (!indexAndNames_.empty()) {
578  if (bigNamesContainer_.back() != '\0') sanityChecksPass = false;
579  if (processNames_.back() != '\0') sanityChecksPass = false;
580  if (maxStart >= bigNamesContainer_.size()) sanityChecksPass = false;
581  unsigned int countZeroes = 0;
582  for (unsigned j = maxStart; j < bigNamesContainer_.size(); ++j) {
583  if (bigNamesContainer_[j] == '\0') {
584  ++countZeroes;
585  }
586  }
587  if (countZeroes != 2) sanityChecksPass = false;
588  if (maxStartProcess >= processNames_.size()) sanityChecksPass = false;
589  countZeroes = 0;
590  for (unsigned j = maxStartProcess; j < processNames_.size(); ++j) {
591  if (processNames_[j] == '\0') {
592  ++countZeroes;
593  }
594  }
595  if (countZeroes != 1) sanityChecksPass = false;
596  }
597 
598  if (!sanityChecksPass) {
600  << "ProductHolderIndexHelper::setFrozen - Detected illegal state.\n";
601  }
602  }
603 
605  TypeID const& typeID,
606  std::string const& moduleLabel,
607  std::string const& instance,
608  std::string const& process,
610  kindOfType_(kindOfType),
611  typeID_(typeID),
612  moduleLabel_(moduleLabel),
613  instance_(instance),
614  process_(process),
615  index_(index) {
616  }
617 
618  bool
620  if (kindOfType_ < right.kindOfType_) return true;
621  if (kindOfType_ > right.kindOfType_) return false;
622  if (typeID_ < right.typeID_) return true;
623  if (typeID_ > right.typeID_) return false;
624  if (moduleLabel_ < right.moduleLabel_) return true;
625  if (moduleLabel_ > right.moduleLabel_) return false;
626  if (instance_ < right.instance_) return true;
627  if (instance_ > right.instance_) return false;
628  return process_ < right.process_;
629  }
630 
631  void ProductHolderIndexHelper::print(std::ostream& os) const {
632 
633  os << "\n******* Dump ProductHolderIndexHelper *************************\n";
634 
635  os << "\nnextIndexValue_ = " << nextIndexValue_ << "\n";
636  os << "beginElements_ = " << beginElements_ << "\n";
637 
638  os << "\n******* sortedTypeIDs_ \n";
639  for (auto const& i : sortedTypeIDs_) {
640  os << i << "\n";
641  }
642  os << "******* ranges_ \n";
643  for (auto const& i : ranges_) {
644  os << i.begin() << " " << i.end() << "\n";
645  }
646  os << "******* indexAndNames_ \n";
647  for (auto const& i : indexAndNames_) {
648  os << i.index() << " " << i.startInBigNamesContainer() << " ";
649  char const* ptr = &bigNamesContainer_[i.startInBigNamesContainer()];
650  while (*ptr) {
651  os << *ptr;
652  ++ptr;
653  }
654  ++ptr;
655  os << " ";
656  while (*ptr) {
657  os << *ptr;
658  ++ptr;
659  }
660  os << " " << i.startInProcessNames() << " ";
661  ptr = &processNames_[i.startInProcessNames()];
662  while (*ptr) {
663  os << *ptr;
664  ++ptr;
665  }
666  os << "\n";
667  }
668  os << "******* bigNamesContainer_ \n";
669  for (auto i : bigNamesContainer_) {
670  if (i == '\0') os << '\\' << '0';
671  else os << i;
672  }
673  if (!bigNamesContainer_.empty()) os << "\n";
674  os << "******* processNames_ \n";
675  for (auto i : processNames_) {
676  if (i == '\0') os << '\\' << '0';
677  else os << i;
678  }
679  if (!processNames_.empty()) os << "\n";
680  if (items_) {
681  os << "******* items_ \n";
682  for (auto const& item : *items_) {
683  std:: cout << item.kindOfType() << " " << item.moduleLabel() << " " << item.instance() << " " << item.process() << " " << item.index() << " " << item.typeID() << "\n";
684  }
685  }
686  if (processItems_) {
687  os << "******* processItems_ \n";
688  for (auto const& item : *processItems_) {
689  os << item << "\n";
690  }
691  }
692  os << "sortedTypeIDs_.size() = " << sortedTypeIDs_.size() << "\n";
693  os << "indexAndNames_.size() = " << indexAndNames_.size() << "\n";
694  os << "bigNamesContainer_.size() = " << bigNamesContainer_.size() << "\n";
695  os << "processNames_.size() = " << processNames_.size() << "\n";
696  os << "\n";
697  }
698 }
Matches relatedIndexes(KindOfType kindOfType, TypeID const &typeID, char const *moduleLabel, char const *instance) const
TypeID getContainedType(TypeID const &typeID)
int i
Definition: DBlmapReader.cc:9
tuple start
Check for commandline option errors.
Definition: dqm_diff.py:58
TypeID getContainedTypeFromWrapper(TypeID const &wrappedtypeID, std::string const &className)
char const * moduleLabel(unsigned int i) const
static PFTauRenderPlugin instance
ProductHolderIndexHelper const * productHolderIndexHelper_
PixelRecoRange< float > Range
ProductHolderIndex index(KindOfType kindOfType, TypeID const &typeID, char const *moduleLabel, char const *instance, char const *process=0) const
std::vector< IndexAndNames > indexAndNames_
char const * processName(unsigned int i) const
void print(std::ostream &os) const
unsigned int ProductHolderIndex
const std::type_info & typeInfo() const
Definition: TypeIDBase.h:58
std::vector< std::string > lookupProcessNames_
static TypeWithDict byName(std::string const &name)
Definition: TypeWithDict.cc:60
void public_base_classes(TypeWithDict const &type, std::vector< TypeWithDict > &baseTypes)
Matches(ProductHolderIndexHelper const *productHolderIndexHelper, unsigned int startInIndexAndNames, unsigned int numberOfMatches)
bool operator<(Item const &right) const
int j
Definition: DBlmapReader.cc:9
unsigned int indexToType(KindOfType kindOfType, TypeID const &typeID) const
ProductHolderIndex index(unsigned int i) const
std::type_info const & typeInfo() const
unsigned int processIndex(char const *process) const
#define end
Definition: vmac.h:37
std::string wrappedClassName(std::string const &iFullName)
#define begin
Definition: vmac.h:30
ProductHolderIndex insert(TypeID const &typeID, char const *moduleLabel, char const *instance, char const *process, TypeID const &containedTypeID)
edm::propagate_const< std::unique_ptr< std::set< Item > > > items_
std::string const & className() const
Definition: TypeID.cc:46
edm::propagate_const< std::unique_ptr< std::set< std::string > > > processItems_
std::vector< std::string > const & lookupProcessNames() const
tuple cout
Definition: gather_cfg.py:145
Item(KindOfType kindOfType, TypeID const &typeID, std::string const &moduleLabel, std::string const &instance, std::string const &process, ProductHolderIndex index)
tuple process
Definition: LaserDQM_cfg.py:3
moduleLabel_(iConfig.getParameter< string >("@module_label"))
std::string className(const T &t)
Definition: ClassName.h:30
unsigned int indexToIndexAndNames(KindOfType kindOfType, TypeID const &typeID, char const *moduleLabel, char const *instance, char const *process) const