本文整理汇总了C++中EventPtr::file方法的典型用法代码示例。如果您正苦于以下问题:C++ EventPtr::file方法的具体用法?C++ EventPtr::file怎么用?C++ EventPtr::file使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类EventPtr
的用法示例。
在下文中一共展示了EventPtr::file方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: allMuons
const LeptonPointer TopPairMuPlusJetsReferenceSelection2011::signalLepton(const EventPtr event) const {
if (!hasExactlyOneIsolatedLepton(event)) {
cerr << "An error occurred in SignalSelection in event (no = " << event->eventnumber();
cerr << ", run = " << event->runnumber() << ", lumi = " << event->lumiblock() << "!" << endl;
cerr << "File = " << event->file() << endl;
cerr
<< "Access exception: No signal lepton could be found. Event doesn't pass 'hasExactlyOneIsolatedLepton' selection"
<< endl;
throw "Access exception: No signal lepton could be found. Event doesn't pass 'hasExactlyOneIsolatedLepton' selection";
}
const MuonCollection allMuons(event->Muons());
MuonCollection goodIsolatedMuons;
for (unsigned int index = 0; index < allMuons.size(); ++index) {
const MuonPointer muon(allMuons.at(index));
if (isGoodMuon(muon) && isIsolated(muon))
goodIsolatedMuons.push_back(muon);
}
return goodIsolatedMuons.front();
}