Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 14:29:40

0001 #ifndef SimG4Core_CustomPhysics_CustomParticle_h
0002 #define SimG4Core_CustomPhysics_CustomParticle_h 1
0003 
0004 #include "G4ParticleDefinition.hh"
0005 #include "globals.hh"
0006 
0007 // ######################################################################
0008 // ###                          CustomParticle                        ###
0009 // ######################################################################
0010 
0011 class CustomParticle : public G4ParticleDefinition {
0012 public:
0013   CustomParticle(const G4String& aName,
0014                  G4double mass,
0015                  G4double width,
0016                  G4double charge,
0017                  G4int iSpin,
0018                  G4int iParity,
0019                  G4int iConjugation,
0020                  G4int iIsospin,
0021                  G4int iIsospin3,
0022                  G4int gParity,
0023                  const G4String& pType,
0024                  G4int lepton,
0025                  G4int baryon,
0026                  G4int encoding,
0027                  G4bool stable,
0028                  G4double lifetime,
0029                  G4DecayTable* decaytable);
0030 
0031 private:
0032   G4ParticleDefinition* m_cloud;
0033   G4ParticleDefinition* m_spec;
0034 
0035 public:
0036   void SetCloud(G4ParticleDefinition* theCloud);
0037   void SetSpectator(G4ParticleDefinition* theSpectator);
0038   G4ParticleDefinition* GetCloud();
0039   G4ParticleDefinition* GetSpectator();
0040   ~CustomParticle() override {}
0041 };
0042 
0043 inline void CustomParticle::SetCloud(G4ParticleDefinition* theCloud) { m_cloud = theCloud; }
0044 inline G4ParticleDefinition* CustomParticle::GetCloud() { return m_cloud; }
0045 inline void CustomParticle::SetSpectator(G4ParticleDefinition* theSpectator) { m_spec = theSpectator; }
0046 inline G4ParticleDefinition* CustomParticle::GetSpectator() { return m_spec; }
0047 
0048 #endif