CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
IterWithDict.cc
Go to the documentation of this file.
2 #include <cassert>
3 
4 namespace edm {
5 
6  IterWithDictBase::IterWithDictBase() : iter_(static_cast<TList*>(nullptr)), atEnd_(true) {
7  // This ctor is used by the framework for the end of a range,
8  // or for any type that does not have a TClass.
9  // An iterator constructed by this ctor must not be used
10  // as the left hand argument of operator!=().
11  }
12 
13  IterWithDictBase::IterWithDictBase(TList* list) : iter_(list), atEnd_(false) {
14  // With a TIter, you must call Next() once to point to the first element.
15  advance();
16  }
17 
18  bool
20  // The special cases are needed because TIter::operator!=()
21  // dereferences a null pointer (i.e. segfaults) if the left hand TIter
22  // was constucted with a nullptr argument (the first constructor above).
23  if(atEnd_ != other.atEnd_) {
24  // one iterator at end, but not both
25  return true;
26  } else if(atEnd_) {
27  // both iterators at end
28  return false;
29  }
30  // neither iterator at end
31  return iter() != other.iter();
32  }
33 
34  void
36  if(!atEnd_) {
37  TObject* obj = iter_.Next();
38  if(obj == nullptr) atEnd_ = true;
39  }
40  }
41 
42  TIter const&
44  return iter_;
45  }
46 
47 }
bool operator!=(IterWithDictBase const &) const
Definition: IterWithDict.cc:19
#define nullptr
TIter const & iter() const
Definition: IterWithDict.cc:43
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger list("!*","!HLTx*"if it matches 2 triggers or more) will accept the event if all the matching triggers are FAIL.It will reject the event if any of the triggers are PASS or EXCEPTION(this matches the behavior of"!*"before the partial wildcard feature was incorporated).Triggers which are in the READY state are completely ignored.(READY should never be returned since the trigger paths have been run