Skip to content

Commit

Permalink
function order matched in interface and implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
ronchese committed Mar 27, 2020
1 parent 70e3863 commit 2608188
Showing 1 changed file with 31 additions and 31 deletions.
62 changes: 31 additions & 31 deletions HeavyFlavorAnalysis/RecoDecay/src/BPHRecoBuilder.cc
Expand Up @@ -71,6 +71,37 @@ const reco::Candidate& BPHRecoBuilder::BPHSpecificCollection<vector<const reco::
return *(*cPtr)[i];
}

void BPHRecoBuilder::add(const string& name, const BPHGenericCollection* collection, double mass, double msig) {
BPHRecoSource* rs;
if (sourceId.find(name) != sourceId.end()) {
edm::LogPrint("TooManyParticles") << "BPHRecoBuilder::add: "
<< "Decay product already inserted with name " << name << " , skipped";
return;
}
rs = new BPHRecoSource;
rs->name = &sourceId.insert(make_pair(name, sourceList.size())).first->first;
rs->collection = collection;
rs->selector.reserve(5);
rs->mass = mass;
rs->msig = msig;
sourceList.push_back(rs);
return;
}

void BPHRecoBuilder::add(const string& name, const vector<BPHRecoConstCandPtr>& collection) {
BPHCompSource* cs;
if (srCompId.find(name) != srCompId.end()) {
edm::LogPrint("TooManyParticles") << "BPHRecoBuilder::add: "
<< "Decay product already inserted with name " << name << " , skipped";
return;
}
cs = new BPHCompSource;
cs->name = &srCompId.insert(make_pair(name, srCompList.size())).first->first;
cs->collection = &collection;
srCompList.push_back(cs);
return;
}

void BPHRecoBuilder::filter(const string& name, const BPHRecoSelect& sel) const {
map<string, int>::const_iterator iter = sourceId.find(name);
if (iter == sourceId.end())
Expand Down Expand Up @@ -177,37 +208,6 @@ bool BPHRecoBuilder::sameTrack(const reco::Candidate* lCand, const reco::Candida
return false;
}

void BPHRecoBuilder::add(const string& name, const BPHGenericCollection* collection, double mass, double msig) {
BPHRecoSource* rs;
if (sourceId.find(name) != sourceId.end()) {
edm::LogPrint("TooManyParticles") << "BPHRecoBuilder::add: "
<< "Decay product already inserted with name " << name << " , skipped";
return;
}
rs = new BPHRecoSource;
rs->name = &sourceId.insert(make_pair(name, sourceList.size())).first->first;
rs->collection = collection;
rs->selector.reserve(5);
rs->mass = mass;
rs->msig = msig;
sourceList.push_back(rs);
return;
}

void BPHRecoBuilder::add(const string& name, const vector<BPHRecoConstCandPtr>& collection) {
BPHCompSource* cs;
if (srCompId.find(name) != srCompId.end()) {
edm::LogPrint("TooManyParticles") << "BPHRecoBuilder::add: "
<< "Decay product already inserted with name " << name << " , skipped";
return;
}
cs = new BPHCompSource;
cs->name = &srCompId.insert(make_pair(name, srCompList.size())).first->first;
cs->collection = &collection;
srCompList.push_back(cs);
return;
}

void BPHRecoBuilder::build(vector<ComponentSet>& compList,
ComponentSet& compSet,
vector<BPHRecoSource*>::const_iterator r_iter,
Expand Down

0 comments on commit 2608188

Please sign in to comment.