50 void operator()(
void*){}
83 parameterSetRegistryFilled_(
false),
84 dataHelper_(branchMap_.getEventTree(),
87 boost::shared_ptr<edm::
EDProductGetter>(new internal::ProductGetter(this)),
90 throw cms::Exception(
"NoFile") <<
"The TFile pointer passed to the constructor was null";
107 <<
" does not contain a branch named 'EventAuxiliary'";
116 <<
" does not contain a branch named 'EventAux'";
135 for(std::vector<char const*>::iterator it =
labels_.begin(), itEnd =
labels_.end();
161 if(eventIndex <
size()) {
176 if (iEntry <
size()) {
186 return to(run, 0U, event);
217 Long64_t
Event::draw(
char const* varexp,
const TCut&
selection, Option_t* option, Long64_t nentries, Long64_t firstentry) {
221 Long64_t
Event::draw(
char const* varexp,
char const*
selection, Option_t* option, Long64_t nentries, Long64_t firstentry) {
225 Long64_t
Event::scan(
char const* varexp,
char const*
selection, Option_t* option, Long64_t nentries, Long64_t firstentry) {
239 return eventIndex != -1 and eventIndex <
size();
250 return eventIndex == -1
or eventIndex ==
size();
254 std::vector<std::string>
const&
259 iproc != eproc; ++iproc) {
269 char const* iModuleLabel,
270 char const* iProductInstanceLabel,
271 char const* iProcessLabel)
const {
277 std::type_info
const& iInfo,
278 char const* iModuleLabel,
279 char const* iProductInstanceLabel,
280 char const* iProcessLabel,
283 throw cms::Exception(
"OffEnd") <<
"You have requested data past the last event";
286 return dataHelper_.
getByLabel(iInfo, iModuleLabel, iProductInstanceLabel, iProcessLabel, oData, eventIndex);
291 char const* iModuleLabel,
292 char const* iProductInstanceLabel,
293 char const* iProcessLabel,
296 throw cms::Exception(
"OffEnd") <<
"You have requested data past the last event";
299 return dataHelper_.
getByLabel(iInfo, iModuleLabel, iProductInstanceLabel, iProcessLabel, holder, eventIndex);
311 if(
auxBranch_->GetEntryNumber() != eventIndex) {
335 throw cms::Exception(
"NoMetaTree") <<
"The TFile does not appear to contain a TTree named "
342 b->SetAddress(&pPhm);
348 b->SetAddress(&pPhv);
350 for (edm::ProcessHistoryVector::const_iterator
i = historyVector.begin(),
e = historyVector.end();
363 if (!eventHistoryBranch)
365 <<
"Failed to find history branch in event history tree";
366 eventHistoryBranch->SetAddress(&pHistory);
372 b->SetAddress(&pEventProcessHistoryIDs);
395 if (names != 0)
return *
names;
401 if (names != 0)
return *
names;
404 <<
"TriggerNames not found in ParameterSet registry";
415 throw cms::Exception(
"NoMetaTree") <<
"The TFile does not contain a TTree named "
423 fft->SetAddress(&fftPtr);
427 typedef std::map<edm::ParameterSetID, edm::ParameterSetBlob> PsetMap;
431 PsetMap *psetMapPtr = &psetMap;
433 b->SetAddress(&psetMapPtr);
440 typedef std::pair<edm::ParameterSetID, edm::ParameterSetBlob> IdToBlobs;
442 IdToBlobs* pIdToBlob = &idToBlob;
444 for(
long long i = 0;
i != psetTree->GetEntries(); ++
i) {
445 psetTree->GetEntry(
i);
446 psetMap.insert(idToBlob);
455 for(PsetMap::const_iterator
i = psetMap.begin(), iEnd = psetMap.end();
468 hTriggerResults.
getByLabel(*
this,
"TriggerResults",
"", process.c_str());
469 if (!hTriggerResults.
isValid()) {
488 <<
"'\n productInstance='" << ((0!=iProduct)?iProduct:
"") <<
"'\n process='" << ((0 != iProcess) ? iProcess :
"") <<
"'\n"
489 "but no data is available for this Event";
496 lumi_ = boost::shared_ptr<fwlite::LuminosityBlock> (
503 lumi_->to(run, lumi);
collection_type::const_iterator const_iterator
const_iterator begin() const
std::string const & idToParameterSetBlobsBranchName()
edm::ProcessHistoryMap historyMap_
Long64_t indexFromEventId(edm::RunNumber_t run, edm::LuminosityBlockNumber_t lumi, edm::EventNumber_t event)
Find index of given event-id.
std::string const & BranchTypeToAuxiliaryBranchName(BranchType const &branchType)
fwlite::DataGetterHelper dataHelper_
virtual edm::TriggerNames const & triggerNames(edm::TriggerResults const &triggerResults) const
edm::EDProductGetter * getter()
static const HistoName names[]
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e< void, edm::EventIDconst &, edm::Timestampconst & > We also list in braces which AR_WATCH_USING_METHOD_ is used for those or
unsigned int EventNumber_t
bool updateEvent(Long_t eventEntry)
virtual bool getByLabel(std::type_info const &, char const *, char const *, char const *, void *) const
This function should only be called by fwlite::Handle<>
virtual std::string const getBranchNameFor(std::type_info const &, char const *, char const *, char const *) const
edm::LuminosityBlockNumber_t luminosityBlock() const
std::string const & fileFormatVersionBranchName()
static ThreadSafeRegistry * instance()
ProcessHistoryRegistry::collection_type ProcessHistoryMap
fwlite::Run const & getRun() const
edm::WrapperHolder getIt(edm::ProductID const &iID) const
TTree * eventHistoryTree_
virtual std::string const getBranchNameFor(std::type_info const &, char const *iModuleLabel, char const *iProductInstanceLabel, char const *iProcessName) const
Return the branch name in the TFile which contains the data.
unsigned int LuminosityBlockNumber_t
Long64_t size() const
Returns number of events in the file.
fwlite::LuminosityBlock const & getLuminosityBlock() const
boost::shared_ptr< fwlite::LuminosityBlock > lumi_
Event const & operator++()
Advance to next event in the TFile.
ProductGetter(Event *iEvent)
EntryNumber_t findEvent(edm::RunNumber_t const &run, edm::LuminosityBlockNumber_t const &lumi, edm::EventNumber_t const &event) const
LuminosityBlockNumber_t luminosityBlock() const
std::string const & parameterSetsTreeName()
void setID(ParameterSetID const &id) const
void getByLabel(const P &iP, const char *iModuleLabel, const char *iProductInstanceLabel=0, const char *iProcessLabel=0)
Long_t getEventEntry() const
boost::shared_ptr< RunFactory > runFactory_
Event const & toBegin()
Go to the very first Event.
TTree * getEventTree() const
std::string const & processHistoryMapBranchName()
int getFileVersion(TFile *file)
edm::IndexIntoFile::EntryNumber_t EntryNumber_t
bool parameterSetRegistryFilled_
std::vector< std::string > procHistoryNames_
boost::shared_ptr< fwlite::Run > run_
std::string const & eventHistoryBranchName()
ProcessHistoryID const & processHistoryID() const
edm::WrapperHolder getByProductID(edm::ProductID const &) const
std::pair< std::string, MonitorElement * > entry
void draw(Option_t *opt)
Properly setup for edm::Ref, etc and then call TTree method.
void updateAux(Long_t eventIndex) const
bool to(Long64_t iIndex)
Go to the event at index iIndex.
std::map< ParameterSetID, ParameterSetID > ParameterSetIdConverter
ProcessHistoryRegistry::vector_type ProcessHistoryVector
virtual edm::EventAuxiliary const & eventAuxiliary() const
void fillIndex(BranchMapReader const &branchMap)
std::string const & metaDataTreeName()
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 but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
std::string const & parameterSetMapBranchName()
std::vector< std::string > const & getProcessHistory() const
std::string className() const
Hash< ProcessHistoryType > ProcessHistoryID
static EntryNumber_t const invalidEntry
std::string const & processHistoryBranchName()
virtual edm::TriggerResultsByName triggerResultsByName(std::string const &process) const
static TriggerNames const * triggerNames_(edm::TriggerResults const &triggerResults)
virtual bool atEnd() const
edm::ProcessHistory const & history() const
void conversion(EventAux const &from, EventAuxiliary &to)
fwlite::BranchMapReader branchMap_
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
std::vector< edm::EventProcessHistoryID > eventProcessHistoryIDs_
ProcessHistoryID const & processHistoryID() const
const_iterator end() const
EventID const & id() const
edm::EventAuxiliary * pAux_
virtual bool getByLabel(std::type_info const &, char const *, char const *, char const *, void *, Long_t) const
static void throwProductNotFoundException(std::type_info const &, char const *, char const *, char const *)
std::string const & eventTreeName()
std::vector< char const * > labels_
std::string const & BranchTypeToAuxBranchName(BranchType const &branchType)
void fillParameterSetRegistry() const
T const * product() const
std::string const & eventHistoryTreeName()
bool insertMapped(value_type const &v)
Long64_t scan(char const *varexp="", char const *selection="", Option_t *option="", Long64_t nentries=1000000000, Long64_t firstentry=0)
edm::WrapperHolder getByProductID(edm::ProductID const &, Long_t) const