Skip to content

Commit

Permalink
added new types for miniaod
Browse files Browse the repository at this point in the history
  • Loading branch information
enibigir committed Dec 2, 2024
1 parent 93af1c7 commit f1b11eb
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 2 deletions.
16 changes: 16 additions & 0 deletions AnalysisDataFormats/SUSYBSMObjects/interface/HSCParticle.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@
#include "DataFormats/GeometryVector/interface/GlobalPoint.h"
#include <vector>

#include "DataFormats/PatCandidates/interface/Muon.h"
#include "DataFormats/PatCandidates/interface/PackedCandidate.h"
#include "DataFormats/PatCandidates/interface/IsolatedTrack.h"
#include "DataFormats/TrackReco/interface/DeDxHitInfo.h"

#include "DataFormats/MuonReco/interface/MuonTimeExtra.h"
#include "AnalysisDataFormats/SUSYBSMObjects/interface/HSCPCaloInfo.h"

Expand Down Expand Up @@ -45,6 +50,8 @@ namespace susybsm {
HSCParticle() {}

// check available infos
bool hasTrack() const { return track_.packedCandRef().isNonnull(); }
bool hasMuon() const { return muon_.isNonnull(); }
bool hasMuonRef() const { return muonRef_.isNonnull(); }
bool hasMTMuonRef() const { return MTMuonRef_.isNonnull(); }
bool hasTrackRef() const { return trackRef_.isNonnull(); }
Expand All @@ -53,6 +60,9 @@ namespace susybsm {
bool hasCaloInfo() const { return caloInfoRef_.isNonnull(); }

// set infos
void setDeDxHitInfo(const reco::DeDxHitInfo* data) {dedxHitInfo_ = data;}
void setTrack(const pat::IsolatedTrack& data) { track_ = data; }
void setMuon(const pat::MuonRef& data) { muon_ = data; }
void setMuon(const reco::MuonRef& data) { muonRef_ = data; }
void setMTMuon(const reco::MuonRef& data) { MTMuonRef_ = data; }
void setTrack(const reco::TrackRef& data) { trackRef_ = data; }
Expand All @@ -61,6 +71,9 @@ namespace susybsm {
void setCaloInfo(const HSCPCaloInfoRef& data) { caloInfoRef_ = data; }

// get infos
const reco::DeDxHitInfo* dedxHitInfo() const {return dedxHitInfo_; }
pat::IsolatedTrack track() const { return track_; }
pat::MuonRef muon() const { return muon_; }
reco::TrackRef trackRef() const { return trackRef_; }
reco::TrackRef trackIsoRef() const { return trackIsoRef_; }
reco::MuonRef muonRef() const { return muonRef_; }
Expand All @@ -74,6 +87,9 @@ namespace susybsm {
int type() const;

private:
const reco::DeDxHitInfo* dedxHitInfo_ = nullptr;
pat::IsolatedTrack track_;
pat::MuonRef muon_;
reco::TrackRef trackRef_; //TrackRef from refitted track collection (dE/dx purposes)
reco::TrackRef trackIsoRef_; //TrackRef from general track collection (isolation purposes)
reco::MuonRef muonRef_;
Expand Down
4 changes: 2 additions & 2 deletions AnalysisDataFormats/SUSYBSMObjects/src/classes_def.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<lcgdict>
<class name="susybsm::HSCParticle" ClassVersion="11">
<version ClassVersion="11" checksum="2205741811"/>
<class name="susybsm::HSCParticle" ClassVersion="12">
<version ClassVersion="12" checksum="3951465682"/>
</class>
<class name="susybsm::RPCBetaMeasurement" ClassVersion="10">
<version ClassVersion="10" checksum="2621605308"/>
Expand Down

0 comments on commit f1b11eb

Please sign in to comment.