G4ParticleChangeForRadDecay.hh

Go to the documentation of this file.
00001 //
00002 // ********************************************************************
00003 // * License and Disclaimer                                           *
00004 // *                                                                  *
00005 // * The  Geant4 software  is  copyright of the Copyright Holders  of *
00006 // * the Geant4 Collaboration.  It is provided  under  the terms  and *
00007 // * conditions of the Geant4 Software License,  included in the file *
00008 // * LICENSE and available at  http://cern.ch/geant4/license .  These *
00009 // * include a list of copyright holders.                             *
00010 // *                                                                  *
00011 // * Neither the authors of this software system, nor their employing *
00012 // * institutes,nor the agencies providing financial support for this *
00013 // * work  make  any representation or  warranty, express or implied, *
00014 // * regarding  this  software system or assume any liability for its *
00015 // * use.  Please see the license in the file  LICENSE  and URL above *
00016 // * for the full disclaimer and the limitation of liability.         *
00017 // *                                                                  *
00018 // * This  code  implementation is the result of  the  scientific and *
00019 // * technical work of the GEANT4 collaboration.                      *
00020 // * By using,  copying,  modifying or  distributing the software (or *
00021 // * any work based  on the software)  you  agree  to acknowledge its *
00022 // * use  in  resulting  scientific  publications,  and indicate your *
00023 // * acceptance of all terms of the Geant4 Software license.          *
00024 // ********************************************************************
00025 //
00026 //
00027 // $Id$
00028 //
00029 // 
00030 // ------------------------------------------------------------
00031 //      GEANT 4 class header file 
00032 //
00033 // 
00034 // ------------------------------------------------------------
00035 //   Implemented for the new scheme                 25 Jan. 2000  H.Kurahige
00036 //
00037 // Class Description
00038 //  This class is a concrete class for ParticleChange for RadDecay
00039 //        
00040 #ifndef G4ParticleChangeForRadDecay_h
00041 #define G4ParticleChangeForRadDecay_h 1
00042 
00043 #include "globals.hh"
00044 #include "G4ios.hh"
00045 class G4VTouchable;
00046 #include "G4ParticleChangeForDecay.hh"
00047 
00048 class G4ParticleChangeForRadDecay: public G4ParticleChangeForDecay
00049 { 
00050   public:
00051     // default constructor
00052     G4ParticleChangeForRadDecay(){}
00053 
00054     // destructor
00055     virtual ~G4ParticleChangeForRadDecay(){}
00056 
00057   protected:
00058     // hide copy constructor and assignment operaor as protected
00059     G4ParticleChangeForRadDecay(const G4ParticleChangeForRadDecay &) : G4ParticleChangeForDecay() {}
00060     G4ParticleChangeForRadDecay & operator=(const G4ParticleChangeForRadDecay &){return *this;}
00061 
00062 
00063   public: // with description
00064   void AddSecondary(G4Track* aSecondary);
00065     //  Add a secondary particle to theListOfSecondaries.
00066     // ------------------------------------------------------   
00067 
00068 
00069 };
00070 
00071 inline void G4ParticleChangeForRadDecay::AddSecondary(G4Track *aTrack)
00072 {
00073   // add a secondary after size check
00074   if (theSizeOftheListOfSecondaries > theNumberOfSecondaries) {
00075     theListOfSecondaries->SetElement(theNumberOfSecondaries, aTrack);
00076     theNumberOfSecondaries++;
00077   } else {
00078 #ifdef G4VERBOSE
00079     if (verboseLevel>0) {
00080       G4cout << "G4VParticleChange::AddSecondary() Warning  ";
00081       G4cout << "theListOfSecondaries is full !! " << G4endl;
00082       G4cout << " The track is deleted " << G4endl;
00083     }
00084 #endif
00085     G4Exception("G4ParticleChangeForRadDecay::AddSecondary",
00086                 "TRACK101", JustWarning,
00087                 "Secondary Bug is full. The track is deleted"); 
00088   }
00089 }
00090 
00091 
00092 
00093 #endif
00094 
00095 
00096 
00097 
00098 
00099 
00100 
00101 
00102 
00103 
00104 
00105 
00106 
00107 
00108 
00109 

Generated on Mon May 27 17:49:15 2013 for Geant4 by  doxygen 1.4.7