EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
starlightparticle.h
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file starlightparticle.h
1 
2 //
3 // Copyright 2010
4 //
5 // This file is part of starlight.
6 //
7 // starlight is free software: you can redistribute it and/or modify
8 // it under the terms of the GNU General Public License as published by
9 // the Free Software Foundation, either version 3 of the License, or
10 // (at your option) any later version.
11 //
12 // starlight is distributed in the hope that it will be useful,
13 // but WITHOUT ANY WARRANTY; without even the implied warranty of
14 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 // GNU General Public License for more details.
16 //
17 // You should have received a copy of the GNU General Public License
18 // along with starlight. If not, see <http://www.gnu.org/licenses/>.
19 //
21 //
22 // File and Version Information:
23 // $Rev:: 263 $: revision of last commit
24 // $Author:: butter $: author of last commit
25 // $Date:: 2016-06-04 23:03:58 +0100 #$: date of last commit
26 //
27 // Description:
28 //
29 //
30 //
32 
33 
34 #ifndef STARLIGHTPARTICLE_H
35 #define STARLIGHTPARTICLE_H
36 
37 
38 #include "lorentzvector.h"
39 
40 
42 {
43  public:
44 
46  starlightParticle ( double px, double py, double pz, double e, double mass, int pdgCode, short charge,
47  double vx = 0., double vy = 0, double vz = 0, double vt = 0,
48  int firstParent = 0, int lastParent = 0, int firstDaughter = 0, int lastDaughter = 0, int status = 0);
49  virtual ~starlightParticle();
50 
51  void setPdgCode(int pdgCode) { _pdgCode = pdgCode; }
52  int getPdgCode() const { return _pdgCode; }
53 
54  void setCharge(short charge) { _charge = charge; }
55  short getCharge() const { return _charge; }
56 
57  void setMass(short mass) { _mass = mass; }
58  short getMass() const { return _mass; }
59 
60  void setFirstParent(int parent) { _firstParent = parent; }
61  void setLastParent(int parent) { _lastParent = parent; }
62  int getFirstParent() const { return _firstParent; }
63  int getLastParent() const { return _lastParent; }
64 
65  void setFirstDaughter(int first) { _firstDaughter = first; }
66  int getFirstDaughter() const { return _firstDaughter; }
67 
68  void setLastDaughter(int first) { _lastDaughter = first; }
69  int getLastDaughter() const { return _lastDaughter; }
70 
71  void setStatus(int status) { _status = status; }
72  int getStatus() const { return _status; }
73 
75  lorentzVector getVertex() const { return _vertex; }
76 
77  void reflect()
78  {
79  this->SetXYZT(-1.0*this->GetPx(),-1.0*this->GetPy(),-1.0*this->GetPz(),this->GetE());
80  _vertex.reflect();
81  };
82 
83 
84  private:
85 
87 
88  int _pdgCode;
89  short _charge;
90  double _mass;
91 
96 
97  int _status;
98 
99 };
100 
101 
102 #endif // STARLIGHTPARTICLE_H