00001
00002
00003 #ifndef XAODTAU_VERSIONS_TAUJET_V1_H
00004 #define XAODTAU_VERSIONS_TAUJET_V1_H
00005
00006
00007
00008 #include "AthLinks/ElementLink.h"
00009
00010
00011
00012 #include "xAODBase/IParticle.h"
00013 #include "xAODBase/IParticleContainer.h"
00014 #include "xAODTau/TauDefs.h"
00015 #include "xAODTracking/TrackParticleContainer.h"
00016 #include "xAODTracking/VertexContainer.h"
00017 #include "xAODJet/JetContainer.h"
00018 #include "xAODPFlow/PFOContainer.h"
00019
00020 namespace xAOD {
00021
00022
00023
00030 class TauJet_v1 : public IParticle {
00031
00032 public:
00034 TauJet_v1();
00035
00038
00040 virtual double pt() const;
00042 virtual double eta() const;
00044 virtual double phi() const;
00046 virtual double e() const;
00047
00049 virtual double m() const;
00051 virtual double rapidity() const;
00052
00054 virtual const FourMom_t& p4() const;
00055 virtual const FourMom_t& p4(const TauJetParameters::TauCalibType calib) const;
00056
00057
00059 void setP4(double pt, double eta, double phi, double m);
00060 bool setP4(const TauJetParameters::TauCalibType calib, double pt, double eta, double phi, double m);
00061
00062
00063 double ptJetSeed() const;
00064 double etaJetSeed() const;
00065 double phiJetSeed() const;
00066 double mJetSeed() const;
00067
00068 double ptDetectorAxis() const;
00069 double etaDetectorAxis() const;
00070 double phiDetectorAxis() const;
00071 double mDetectorAxis() const;
00072
00073 double ptIntermediateAxis() const;
00074 double etaIntermediateAxis() const;
00075 double phiIntermediateAxis() const;
00076 double mIntermediateAxis() const;
00077
00078 double ptTauEnergyScale() const;
00079 double etaTauEnergyScale() const;
00080 double phiTauEnergyScale() const;
00081 double mTauEnergyScale() const;
00082
00083 double ptTauEtaCalib() const;
00084 double etaTauEtaCalib() const;
00085 double phiTauEtaCalib() const;
00086 double mTauEtaCalib() const;
00087
00088 double ptPanTauEFlowRecProto() const;
00089 double etaPanTauEFlowRecProto() const;
00090 double phiPanTauEFlowRecProto() const;
00091 double mPanTauEFlowRecProto() const;
00092
00093 double ptPanTauEFlowRec() const;
00094 double etaPanTauEFlowRec() const;
00095 double phiPanTauEFlowRec() const;
00096 double mPanTauEFlowRec() const;
00097
00098 double ptPanTauCellBasedProto() const;
00099 double etaPanTauCellBasedProto() const;
00100 double phiPanTauCellBasedProto() const;
00101 double mPanTauCellBasedProto() const;
00102
00103 double ptPanTauCellBased() const;
00104 double etaPanTauCellBased() const;
00105 double phiPanTauCellBased() const;
00106 double mPanTauCellBased() const;
00107
00109 virtual Type::ObjectType type() const;
00110
00112
00113
00114 float charge() const;
00115
00116
00117 void setCharge(float);
00118
00120 unsigned int ROIWord() const;
00121
00122
00123 void setROIWord(unsigned int);
00124
00127 bool hasDiscriminant( TauJetParameters::TauID discID ) const;
00128
00131 double discriminant( TauJetParameters::TauID discID ) const;
00132
00136 void setDiscriminant( TauJetParameters::TauID discID, double disc );
00137
00140 bool isTau( TauJetParameters::IsTauFlag flag ) const;
00141
00145 void setIsTau( TauJetParameters::IsTauFlag flag, bool value );
00146
00150 void setFlag( TauJetParameters::VetoFlags flag, bool value );
00151
00154 bool flag( TauJetParameters::VetoFlags flag ) const;
00155
00156
00158 bool detail( TauJetParameters::Detail detail, int& value ) const;
00159 bool detail( TauJetParameters::Detail detail, float& value ) const;
00160 void setDetail( TauJetParameters::Detail detail, int value );
00161 void setDetail( TauJetParameters::Detail detail, float value );
00162
00163
00164 template <class T>
00165 typename xAODTAU_return_type<T>::type detail( TauJetParameters::Detail detail ) const
00166 {
00167 T temp;
00168 if (this->detail(detail,temp)) return temp;
00169 else return 0;
00170 }
00171
00173 bool panTauDetail( TauJetParameters::PanTauDetails panTauDetail, int& value ) const;
00174 bool panTauDetail( TauJetParameters::PanTauDetails panTauDetail, float& value ) const;
00175 void setPanTauDetail( TauJetParameters::PanTauDetails panTauDetail, int value );
00176 void setPanTauDetail( TauJetParameters::PanTauDetails panTauDetail, float value );
00177
00178
00179 template <class T>
00180 typename xAODTAU_return_type<T>::type panTauDetail( TauJetParameters::PanTauDetails panTauDetail ) const
00181 {
00182 T temp;
00183 if (this->panTauDetail(panTauDetail,temp)) return temp;
00184 else return 0;
00185 }
00186
00187
00188 typedef ElementLink< xAOD::JetContainer > JetLink_t;
00189
00190 const JetLink_t& jetLink() const;
00191
00192 void setJetLink( const JetLink_t& jetLink );
00193
00194 void setJet( const xAOD::JetContainer *cont, const xAOD::Jet *jet );
00195
00196 const Jet* jet() const;
00197
00198
00199
00200 typedef ElementLink< xAOD::VertexContainer > VertexLink_t;
00201
00202 const VertexLink_t& vertexLink() const;
00203
00204 void setVertexLink( const VertexLink_t& vertexLink );
00205
00206 void setVertex( const xAOD::VertexContainer *cont, const xAOD::Vertex *vertex );
00207
00208 const Vertex* vertex() const;
00209
00210
00211
00212
00213 const VertexLink_t& secondaryVertexLink() const;
00214
00215 void setSecondaryVertexLink( const VertexLink_t& vertexLink );
00216
00217 void setSecondaryVertex( const xAOD::VertexContainer *cont, const xAOD::Vertex *vertex );
00218
00219 const Vertex* secondaryVertex() const;
00220
00221
00222
00223
00224 typedef std::vector< ElementLink< xAOD::TrackParticleContainer > > TrackParticleLinks_t;
00225
00226 const TrackParticleLinks_t& trackLinks() const;
00227
00228 void setTrackLinks( const TrackParticleLinks_t& trackParticles );
00230 const TrackParticle* track( size_t i ) const;
00232 size_t nTracks() const;
00234 void addTrackLink( const ElementLink< TrackParticleContainer >& tr);
00236 void clearTrackLinks();
00237
00238
00239 int trackFilterPass(unsigned int numTrack) const;
00240
00241 void setTrackFilterPass(unsigned int numTrack, int pass);
00242
00243
00244 int trackFilterProngs() const;
00245
00246 void setTrackFilterProngs(int);
00247
00248
00249 int trackFilterQuality() const;
00250
00251 void setTrackFilterQuality(int);
00252
00253
00254 float pi0ConeDR() const;
00255
00256 void setPi0ConeDR(float);
00257
00258
00259
00260 float trackEtaStrip(unsigned int numTrack) const;
00261
00262 void setTrackEtaStrip(unsigned int numTrack, float eta);
00263
00264
00265
00266 float trackPhiStrip(unsigned int numTrack) const;
00267
00268 void setTrackPhiStrip(unsigned int numTrack, float phi);
00269
00270
00271
00272 const TrackParticleLinks_t& conversionTrackLinks() const;
00273
00274 void setConversionTrackLinks( const TrackParticleLinks_t& trackParticles );
00276 const TrackParticle* conversionTrack( size_t i ) const;
00278 size_t nConversionTracks() const;
00280 void addConversionTrackLink( const ElementLink< TrackParticleContainer >& tr);
00282 void clearConversionTrackLinks();
00283
00284
00285
00286 const TrackParticleLinks_t& wideTrackLinks() const;
00287
00288 void setWideTrackLinks( const TrackParticleLinks_t& trackParticles );
00290 const TrackParticle* wideTrack( size_t i ) const;
00292 size_t nWideTracks() const;
00294 void addWideTrackLink( const ElementLink< TrackParticleContainer >& tr);
00296 void clearWideTrackLinks();
00297
00298
00299
00300 const TrackParticleLinks_t& otherTrackLinks() const;
00301
00302 void setOtherTrackLinks( const TrackParticleLinks_t& trackParticles );
00304 const TrackParticle* otherTrack( size_t i ) const;
00306 size_t nOtherTracks() const;
00308 void addOtherTrackLink( const ElementLink< TrackParticleContainer >& tr);
00310 void clearOtherTrackLinks();
00311
00312
00313
00314 typedef std::vector< ElementLink< xAOD::PFOContainer > > PFOLinks_t;
00315
00316
00317
00318 const PFOLinks_t& hadronic_PFOLinks() const;
00319
00320 void setHadronic_PFOLinks( const PFOLinks_t& hadronic_PFOs );
00322 const PFO* hadronic_PFO( size_t i ) const;
00324 size_t nHadronic_PFOs() const;
00326 void addHadronic_PFOLink( const ElementLink< PFOContainer >& pfo);
00328 void clearHadronic_PFOLinks();
00329
00330
00331
00332 const PFOLinks_t& shot_PFOLinks() const;
00333
00334 void setShot_PFOLinks( const PFOLinks_t& shot_PFOs );
00336 const PFO* shot_PFO( size_t i ) const;
00338 size_t nShot_PFOs() const;
00340 void addShot_PFOLink( const ElementLink< PFOContainer >& pfo);
00342 void clearShot_PFOLinks();
00343
00344
00346
00347
00348 const PFOLinks_t& charged_PFOLinks() const;
00349
00350 void setCharged_PFOLinks( const PFOLinks_t& charged_PFOs );
00352 const PFO* charged_PFO( size_t i ) const;
00354 size_t nCharged_PFOs() const;
00356 void addCharged_PFOLink( const ElementLink< PFOContainer >& pfo);
00358 void clearCharged_PFOLinks();
00359
00360
00361
00362 const PFOLinks_t& neutral_PFOLinks() const;
00363
00364 void setNeutral_PFOLinks( const PFOLinks_t& neutral_PFOs );
00366 const PFO* neutral_PFO( size_t i ) const;
00368 size_t nNeutral_PFOs() const;
00370 void addNeutral_PFOLink( const ElementLink< PFOContainer >& pfo);
00372 void clearNeutral_PFOLinks();
00373
00374
00375
00376 const PFOLinks_t& pi0_PFOLinks() const;
00377
00378 void setPi0_PFOLinks( const PFOLinks_t& pi0_PFOs );
00380 const PFO* pi0_PFO( size_t i ) const;
00382 size_t nPi0_PFOs() const;
00384 void addPi0_PFOLink( const ElementLink< PFOContainer >& pfo);
00386 void clearPi0_PFOLinks();
00387
00388
00389
00390
00392
00393
00394 const PFOLinks_t& cellBased_Charged_PFOLinks() const;
00395
00396 void setCellBased_Charged_PFOLinks( const PFOLinks_t& cellBased_Charged_PFOs );
00398 const PFO* cellBased_Charged_PFO( size_t i ) const;
00400 size_t nCellBased_Charged_PFOs() const;
00402 void addCellBased_Charged_PFOLink( const ElementLink< PFOContainer >& pfo);
00404 void clearCellBased_Charged_PFOLinks();
00405
00406
00407
00408 const PFOLinks_t& cellBased_Neutral_PFOLinks() const;
00409
00410 void setCellBased_Neutral_PFOLinks( const PFOLinks_t& cellBased_Neutral_PFOs );
00412 const PFO* cellBased_Neutral_PFO( size_t i ) const;
00414 size_t nCellBased_Neutral_PFOs() const;
00416 void addCellBased_Neutral_PFOLink( const ElementLink< PFOContainer >& pfo);
00418 void clearCellBased_Neutral_PFOLinks();
00419
00420
00421
00422 const PFOLinks_t& cellBased_Pi0_PFOLinks() const;
00423
00424 void setCellBased_Pi0_PFOLinks( const PFOLinks_t& cellBased_Pi0_PFOs );
00426 const PFO* cellBased_Pi0_PFO( size_t i ) const;
00428 size_t nCellBased_Pi0_PFOs() const;
00430 void addCellBased_Pi0_PFOLink( const ElementLink< PFOContainer >& pfo);
00432 void clearCellBased_Pi0_PFOLinks();
00433
00434
00435
00436
00438
00439
00440 const PFOLinks_t& eflowRec_Charged_PFOLinks() const;
00441
00442 void setEflowRec_Charged_PFOLinks( const PFOLinks_t& eflowRec_Charged_PFOs );
00444 const PFO* eflowRec_Charged_PFO( size_t i ) const;
00446 size_t nEflowRec_Charged_PFOs() const;
00448 void addEflowRec_Charged_PFOLink( const ElementLink< PFOContainer >& pfo);
00450 void clearEflowRec_Charged_PFOLinks();
00451
00452
00453
00454 const PFOLinks_t& eflowRec_Neutral_PFOLinks() const;
00455
00456 void setEflowRec_Neutral_PFOLinks( const PFOLinks_t& eflowRec_Neutral_PFOs );
00458 const PFO* eflowRec_Neutral_PFO( size_t i ) const;
00460 size_t nEflowRec_Neutral_PFOs() const;
00462 void addEflowRec_Neutral_PFOLink( const ElementLink< PFOContainer >& pfo);
00464 void clearEflowRec_Neutral_PFOLinks();
00465
00466
00467
00468 const PFOLinks_t& eflowRec_Pi0_PFOLinks() const;
00469
00470 void setEflowRec_Pi0_PFOLinks( const PFOLinks_t& eflowRec_Pi0_PFOs );
00472 const PFO* eflowRec_Pi0_PFO( size_t i ) const;
00474 size_t nEflowRec_Pi0_PFOs() const;
00476 void addEflowRec_Pi0_PFOLink( const ElementLink< PFOContainer >& pfo);
00478 void clearEflowRec_Pi0_PFOLinks();
00479
00480
00482
00483
00484 void dump();
00485
00486 private:
00487
00489 mutable FourMom_t m_p4;
00491 mutable bool m_p4Cached;
00492
00493
00494
00495 };
00496
00497 }
00498
00499
00500 #include "AthContainers/DataVector.h"
00501 DATAVECTOR_BASE( xAOD::TauJet_v1, xAOD::IParticle );
00502
00503 #endif // XAODTAU_VERSIONS_TAUJET_V1_H
00504
00505