ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/MitAna/DataTree/interface/Photon.h
Revision: 1.3
Committed: Wed Jul 2 19:28:43 2008 UTC (16 years, 10 months ago) by bendavid
Content type: text/plain
Branch: MAIN
Changes since 1.2: +13 -19 lines
Log Message:
moved details of photon conversions into seperate Conversion class

File Contents

# User Rev Content
1 loizides 1.1 //--------------------------------------------------------------------------------------------------
2 bendavid 1.3 // $Id: Photon.h,v 1.2 2008/07/01 09:16:49 loizides Exp $
3 loizides 1.1 //
4     // Photon
5     //
6     // Details to be worked out...
7     //
8 loizides 1.2 // Authors: J.Bendavid, C.Loizides
9 loizides 1.1 //--------------------------------------------------------------------------------------------------
10    
11     #ifndef DATATREE_PHOTON_H
12     #define DATATREE_PHOTON_H
13    
14 bendavid 1.3 #include "MitAna/DataTree/interface/Particle.h"
15     #include "MitAna/DataTree/interface/Types.h"
16     #include "MitAna/DataTree/interface/RefArray.h"
17     #include "MitAna/DataTree/interface/Conversion.h"
18 loizides 1.1
19     namespace mithep
20     {
21 bendavid 1.3 class Photon : public Particle
22 loizides 1.1 {
23     public:
24     Photon() {}
25     Photon(Double_t px, Double_t py, Double_t pz, Double_t e) : fFourVector(px,py,pz,e) {}
26     ~Photon() {}
27 loizides 1.2
28 bendavid 1.3 void AddConversion(Conversion *c) { fConversions.Add(c); }
29     Int_t Charge() const { return 0; }
30     Bool_t IsConverted() const { return fConversions.GetEntries(); }
31     const Conversion *GetConversion(UInt_t i) const { return fConversions.At(i); }
32     UInt_t GetNConversions() const { return fConversions.GetEntries(); }
33     FourVector Mom() const { return fFourVector; }
34 loizides 1.2 void SetMom(Double_t px, Double_t py, Double_t pz, Double_t e);
35 loizides 1.1
36     protected:
37 loizides 1.2 FourVector fFourVector; //four momentum vector
38 bendavid 1.3 RefArray<Conversion> fConversions; //references to associated conversion candidates
39 loizides 1.1
40 loizides 1.2 ClassDef(Photon,1) // Photon class
41 loizides 1.1 };
42     }
43 loizides 1.2
44     //--------------------------------------------------------------------------------------------------
45     inline void mithep::Photon::SetMom(Double_t px, Double_t py, Double_t pz, Double_t e)
46     {
47     // Set four vector.
48    
49     fFourVector.SetXYZT(px, py, pz, e);
50     }
51 loizides 1.1 #endif