Import Geant4 10.5.1 source tree

This commit is contained in:
Gabriele Cosmo
2019-04-17 10:39:02 +02:00
parent a7fdc52004
commit 28a70706e0
661 changed files with 55791 additions and 106984 deletions
+12
View File
@@ -16,6 +16,18 @@ committal in the CVS repository !
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
- 09 April 2019 Gabriele Cosmo (particles-V10-04-13)
- Fixed typo in G4ElectronOccupancy::operator==().
- 13 Mar 2019 Makoto Asai
- G4NuclideTableMessenger.cc : fixing a typo.
- 31 Jan 2019 Ivana Hrivnacova
- Merged GitHub PR #4: all Boolean operators now return G4bool.
- 14 Dec 2018 Makoto Asai
- G4PrimaryParticle.cc: Allowing absolute zero proper decay time.
- 09 Nov 2018 Gabriele Cosmo (particles-V10-04-12)
- G4PrimaryVertex: fixed typo in class description.
@@ -61,8 +61,8 @@ class G4DecayProducts
~G4DecayProducts();
// (un)equal operator
G4int operator==(const G4DecayProducts &right) const;
G4int operator!=(const G4DecayProducts &right) const;
G4bool operator==(const G4DecayProducts &right) const;
G4bool operator!=(const G4DecayProducts &right) const;
public: // With Description
// set-get methods for the parent particle
@@ -104,13 +104,13 @@ class G4DecayProducts
// ------------------------
inline
G4int G4DecayProducts::operator==(const G4DecayProducts &right) const
G4bool G4DecayProducts::operator==(const G4DecayProducts &right) const
{
return (this == (G4DecayProducts *) &right);
}
inline
G4int G4DecayProducts::operator!=(const G4DecayProducts &right) const
G4bool G4DecayProducts::operator!=(const G4DecayProducts &right) const
{
return (this != (G4DecayProducts *) &right);
}
@@ -69,8 +69,8 @@ class G4DecayTable
public:
// equality operators
G4int operator==(const G4DecayTable &right) const {return (this == &right);};
G4int operator!=(const G4DecayTable &right) const {return (this != &right);};
G4bool operator==(const G4DecayTable &right) const {return (this == &right);};
G4bool operator!=(const G4DecayTable &right) const {return (this != &right);};
public: // With Description
void Insert( G4VDecayChannel* aChannel);
@@ -104,8 +104,8 @@ class G4DynamicParticle
//- operators
G4DynamicParticle & operator=(const G4DynamicParticle &right);
G4int operator==(const G4DynamicParticle &right) const;
G4int operator!=(const G4DynamicParticle &right) const;
G4bool operator==(const G4DynamicParticle &right) const;
G4bool operator!=(const G4DynamicParticle &right) const;
// new/delete operators are oberloded to use G4Allocator
inline void *operator new(size_t);
@@ -77,8 +77,8 @@ class G4ElectronOccupancy
//- operators
G4ElectronOccupancy & operator=(const G4ElectronOccupancy &right);
G4int operator==(const G4ElectronOccupancy &right) const;
G4int operator!=(const G4ElectronOccupancy &right) const;
G4bool operator==(const G4ElectronOccupancy &right) const;
G4bool operator!=(const G4ElectronOccupancy &right) const;
public: // With Description
// The following methods returns
@@ -57,8 +57,8 @@ class G4IsotopeProperty
G4IsotopeProperty & operator=(G4IsotopeProperty& right);
// equal / unequal operator
G4int operator==(const G4IsotopeProperty &right) const;
G4int operator!=(const G4IsotopeProperty &right) const;
G4bool operator==(const G4IsotopeProperty &right) const;
G4bool operator!=(const G4IsotopeProperty &right) const;
// destructor
virtual ~G4IsotopeProperty();
@@ -204,8 +204,8 @@ class G4ParticleDefinition
// true only if the particle is a G4MuonicAtom
// (it means that theProcessManager is same as the one for G4GenricMuonicAtom)
G4int operator==(const G4ParticleDefinition &right) const;
G4int operator!=(const G4ParticleDefinition &right) const;
G4bool operator==(const G4ParticleDefinition &right) const;
G4bool operator!=(const G4ParticleDefinition &right) const;
public : // without description
@@ -64,8 +64,8 @@ class G4ParticlePropertyData
G4ParticlePropertyData & operator=(const G4ParticlePropertyData &right);
G4int operator==(const G4ParticlePropertyData &right) const;
G4int operator!=(const G4ParticlePropertyData &right) const;
G4bool operator==(const G4ParticlePropertyData &right) const;
G4bool operator!=(const G4ParticlePropertyData &right) const;
public: // With Description
// By these following Getxxxx methods, you can get values
@@ -59,8 +59,8 @@ class G4ParticlePropertyTable
G4ParticlePropertyTable & operator=(const G4ParticlePropertyTable &right);
public:
G4int operator==(const G4ParticlePropertyTable &right) const;
G4int operator!=(const G4ParticlePropertyTable &right) const;
G4bool operator==(const G4ParticlePropertyTable &right) const;
G4bool operator!=(const G4ParticlePropertyTable &right) const;
public:
virtual ~G4ParticlePropertyTable();
@@ -93,8 +93,8 @@ class G4PrimaryParticle
G4PrimaryParticle & operator=(const G4PrimaryParticle &right);
// equal operator returns 'true' only if the same object (i.e comarison by pointer value)
G4int operator==(const G4PrimaryParticle &right) const;
G4int operator!=(const G4PrimaryParticle &right) const;
G4bool operator==(const G4PrimaryParticle &right) const;
G4bool operator!=(const G4PrimaryParticle &right) const;
public: // with description
void Print() const;
@@ -60,8 +60,8 @@ class G4PrimaryVertex
G4PrimaryVertex(const G4PrimaryVertex &right);
G4PrimaryVertex & operator=(const G4PrimaryVertex &right);
G4int operator==(const G4PrimaryVertex &right) const;
G4int operator!=(const G4PrimaryVertex &right) const;
G4bool operator==(const G4PrimaryVertex &right) const;
G4bool operator!=(const G4PrimaryVertex &right) const;
public: // with description
G4ThreeVector GetPosition() const;
@@ -72,11 +72,11 @@ class G4VDecayChannel
virtual ~G4VDecayChannel();
// equality operators
G4int operator==(const G4VDecayChannel &right) const {return (this == &right);}
G4int operator!=(const G4VDecayChannel &right) const {return (this != &right);}
G4bool operator==(const G4VDecayChannel &right) const {return (this == &right);}
G4bool operator!=(const G4VDecayChannel &right) const {return (this != &right);}
// less-than operator is defined for G4DecayTable
G4int operator<(const G4VDecayChannel &right) const;
G4bool operator<(const G4VDecayChannel &right) const;
virtual G4DecayProducts* DecayIt(G4double parentMass = -1.0) = 0;
@@ -202,7 +202,7 @@ class G4VDecayChannel
// ------------------------------------------------------------
inline
G4int G4VDecayChannel::operator<(const G4VDecayChannel &right) const
G4bool G4VDecayChannel::operator<(const G4VDecayChannel &right) const
{
return (this->rbranch < right.rbranch);
}
@@ -337,13 +337,13 @@ void G4DynamicParticle::SetDefinition(const G4ParticleDefinition * aParticleDefi
}
////////////////////
G4int G4DynamicParticle::operator==(const G4DynamicParticle &right) const
G4bool G4DynamicParticle::operator==(const G4DynamicParticle &right) const
{
return (this == (G4DynamicParticle *) &right);
}
////////////////////
G4int G4DynamicParticle::operator!=(const G4DynamicParticle &right) const
G4bool G4DynamicParticle::operator!=(const G4DynamicParticle &right) const
{
return (this != (G4DynamicParticle *) &right);
}
@@ -104,7 +104,7 @@ G4ElectronOccupancy& G4ElectronOccupancy::operator=(const G4ElectronOccupancy& r
return *this;
}
G4int G4ElectronOccupancy::operator==(const G4ElectronOccupancy& right) const
G4bool G4ElectronOccupancy::operator==(const G4ElectronOccupancy& right) const
{
G4int index;
G4bool value = true;
@@ -113,15 +113,15 @@ G4int G4ElectronOccupancy::operator==(const G4ElectronOccupancy& right) const
value = value &&
(theOccupancies[index] == right.theOccupancies[index]) ;
} else if ((index < theSizeOfOrbit ) && ( index >= right.theSizeOfOrbit)) {
value = value && (theOccupancies[index] == 0);
value = value && (theOccupancies[index] == false);
} else if ((index >= theSizeOfOrbit ) && ( index <right.theSizeOfOrbit)) {
value = value && (right.theOccupancies[index] == 0);
value = value && (right.theOccupancies[index] == false);
}
}
return value;
}
G4int G4ElectronOccupancy::operator!=(const G4ElectronOccupancy& right) const
G4bool G4ElectronOccupancy::operator!=(const G4ElectronOccupancy& right) const
{
return !(*this == right);
}
@@ -96,7 +96,7 @@ G4IsotopeProperty & G4IsotopeProperty::operator=(G4IsotopeProperty& right)
// equal / unequal operator
G4int G4IsotopeProperty::operator==(const G4IsotopeProperty &right) const
G4bool G4IsotopeProperty::operator==(const G4IsotopeProperty &right) const
{
G4bool value = true;
value = value && ( fAtomicNumber == right.fAtomicNumber);
@@ -110,7 +110,7 @@ G4int G4IsotopeProperty::operator==(const G4IsotopeProperty &right) const
return value;
}
G4int G4IsotopeProperty::operator!=(const G4IsotopeProperty &right) const
G4bool G4IsotopeProperty::operator!=(const G4IsotopeProperty &right) const
{
return !(*this == right);
}
@@ -67,7 +67,7 @@ G4NuclideTableMessenger::G4NuclideTableMessenger(G4NuclideTable* nuclideTable)
///particle/manage/nuclide/level_tolerance
lToleranceCmd = new G4UIcmdWithADoubleAndUnit("/particle/nuclideTable/level_tolerance",this);
lToleranceCmd->SetGuidance("Set tolerance in level seaching.");
lToleranceCmd->SetGuidance("Set tolerance in level searching.");
lToleranceCmd->SetGuidance("Unit of the energy can be :");
lToleranceCmd->SetGuidance(" MeV, keV, eV (default)");
lToleranceCmd->SetParameterName("lTolerance",false);
@@ -229,12 +229,12 @@ const G4ParticleDefinition & G4ParticleDefinition::operator=(const G4ParticleDef
return *this;
}
G4int G4ParticleDefinition::operator==(const G4ParticleDefinition &right) const
G4bool G4ParticleDefinition::operator==(const G4ParticleDefinition &right) const
{
return (this->theParticleName == right.theParticleName);
}
G4int G4ParticleDefinition::operator!=(const G4ParticleDefinition &right) const
G4bool G4ParticleDefinition::operator!=(const G4ParticleDefinition &right) const
{
return (this->theParticleName != right.theParticleName);
}
@@ -184,13 +184,13 @@ G4ParticlePropertyData & G4ParticlePropertyData::operator=(const G4ParticlePrope
}
////////////////////////
G4int G4ParticlePropertyData::operator==(const G4ParticlePropertyData &right) const
G4bool G4ParticlePropertyData::operator==(const G4ParticlePropertyData &right) const
{
return (this == &right);
}
////////////////////////
G4int G4ParticlePropertyData::operator!=(const G4ParticlePropertyData &right) const
G4bool G4ParticlePropertyData::operator!=(const G4ParticlePropertyData &right) const
{
return (this != &right);
}
@@ -85,13 +85,13 @@ G4ParticlePropertyTable & G4ParticlePropertyTable::operator=(const G4ParticlePro
}
////////////////////////
G4int G4ParticlePropertyTable::operator==(const G4ParticlePropertyTable &) const
G4bool G4ParticlePropertyTable::operator==(const G4ParticlePropertyTable &) const
{
return true;
}
////////////////////////
G4int G4ParticlePropertyTable::operator!=(const G4ParticlePropertyTable &) const
G4bool G4ParticlePropertyTable::operator!=(const G4ParticlePropertyTable &) const
{
return false;
}
@@ -44,7 +44,7 @@ G4PrimaryParticle::G4PrimaryParticle()
direction(0.,0.,1.),kinE(0.),
nextParticle(0),daughterParticle(0),trackID(-1),
mass(-1.),charge(0.),polX(0.),polY(0.),polZ(0.),
Weight0(1.0),properTime(0.0),userInfo(0)
Weight0(1.0),properTime(-1.0),userInfo(0)
{;}
G4PrimaryParticle::G4PrimaryParticle(G4int Pcode)
@@ -52,7 +52,7 @@ G4PrimaryParticle::G4PrimaryParticle(G4int Pcode)
direction(0.,0.,1.),kinE(0.),
nextParticle(0),daughterParticle(0),trackID(-1),
mass(-1.),charge(0.),polX(0.),polY(0.),polZ(0.),
Weight0(1.0),properTime(0.0),userInfo(0)
Weight0(1.0),properTime(-1.0),userInfo(0)
{
G4code = G4ParticleTable::GetParticleTable()->FindParticle(Pcode);
if (G4code !=0) {
@@ -67,7 +67,7 @@ G4PrimaryParticle::G4PrimaryParticle(G4int Pcode,
direction(0.,0.,1.),kinE(0.),
nextParticle(0),daughterParticle(0),trackID(-1),
mass(-1.),charge(0.),polX(0.),polY(0.),polZ(0.),
Weight0(1.0),properTime(0.0),userInfo(0)
Weight0(1.0),properTime(-1.0),userInfo(0)
{
G4code = G4ParticleTable::GetParticleTable()->FindParticle(Pcode);
if (G4code !=0) {
@@ -83,7 +83,7 @@ G4PrimaryParticle::G4PrimaryParticle(G4int Pcode,
direction(0.,0.,1.),kinE(0.),
nextParticle(0),daughterParticle(0),trackID(-1),
mass(-1.),charge(0.),polX(0.),polY(0.),polZ(0.),
Weight0(1.0),properTime(0.0),userInfo(0)
Weight0(1.0),properTime(-1.0),userInfo(0)
{
G4code = G4ParticleTable::GetParticleTable()->FindParticle(Pcode);
if (G4code !=0) {
@@ -98,7 +98,7 @@ G4PrimaryParticle::G4PrimaryParticle(const G4ParticleDefinition* Gcode)
direction(0.,0.,1.),kinE(0.),
nextParticle(0),daughterParticle(0),trackID(-1),
mass(-1.),charge(0.),polX(0.),polY(0.),polZ(0.),
Weight0(1.0),properTime(0.0),userInfo(0)
Weight0(1.0),properTime(-1.0),userInfo(0)
{
if (G4code !=0) {
PDGcode = Gcode->GetPDGEncoding();
@@ -113,7 +113,7 @@ G4PrimaryParticle::G4PrimaryParticle(const G4ParticleDefinition* Gcode,
direction(0.,0.,1.),kinE(0.),
nextParticle(0),daughterParticle(0),trackID(-1),
mass(-1.),charge(0.),polX(0.),polY(0.),polZ(0.),
Weight0(1.0),properTime(0.0),userInfo(0)
Weight0(1.0),properTime(-1.0),userInfo(0)
{
if (G4code !=0) {
PDGcode = Gcode->GetPDGEncoding();
@@ -129,7 +129,7 @@ G4PrimaryParticle::G4PrimaryParticle(const G4ParticleDefinition* Gcode,
direction(0.,0.,1.),kinE(0.),
nextParticle(0),daughterParticle(0),trackID(-1),
mass(-1.),charge(0.),polX(0.),polY(0.),polZ(0.),
Weight0(1.0),properTime(0.0),userInfo(0)
Weight0(1.0),properTime(-1.0),userInfo(0)
{
if (G4code !=0) {
PDGcode = Gcode->GetPDGEncoding();
@@ -144,7 +144,7 @@ G4PrimaryParticle::G4PrimaryParticle(const G4PrimaryParticle& right)
direction(0.,0.,1.),kinE(0.),
nextParticle(0),daughterParticle(0),trackID(-1),
mass(-1.),charge(0.),polX(0.),polY(0.),polZ(0.),
Weight0(1.0),properTime(0.0),userInfo(0)
Weight0(1.0),properTime(-1.0),userInfo(0)
{
*this = right;
}
@@ -184,10 +184,10 @@ G4PrimaryParticle & G4PrimaryParticle::operator=(const G4PrimaryParticle & right
return *this;
}
G4int G4PrimaryParticle::operator==(const G4PrimaryParticle &right) const
G4bool G4PrimaryParticle::operator==(const G4PrimaryParticle &right) const
{ return (this==&right); }
G4int G4PrimaryParticle::operator!=(const G4PrimaryParticle &right) const
G4bool G4PrimaryParticle::operator!=(const G4PrimaryParticle &right) const
{ return (this!=&right); }
G4PrimaryParticle::~G4PrimaryParticle()
@@ -284,7 +284,7 @@ void G4PrimaryParticle::Print() const
<< polZ << " )"
<< G4endl;
G4cout << " Weight : " << Weight0 << G4endl;
if(properTime>0.0) {
if(properTime>=0.0) {
G4cout << " PreAssigned proper decay time : " << properTime/ns << " [ns] " << G4endl;
}
if(userInfo != 0) { userInfo->Print(); }
@@ -135,10 +135,10 @@ G4PrimaryVertex & G4PrimaryVertex::operator=(const G4PrimaryVertex & right)
return *this;
}
G4int G4PrimaryVertex::operator==(const G4PrimaryVertex &right) const
G4bool G4PrimaryVertex::operator==(const G4PrimaryVertex &right) const
{ return (this==&right); }
G4int G4PrimaryVertex::operator!=(const G4PrimaryVertex &right) const
G4bool G4PrimaryVertex::operator!=(const G4PrimaryVertex &right) const
{ return (this!=&right); }
G4PrimaryParticle* G4PrimaryVertex::GetPrimary(G4int i) const
@@ -71,8 +71,8 @@ class G4VShortLivedParticle : public G4ParticleDefinition
virtual ~G4VShortLivedParticle();
G4int operator==(const G4VShortLivedParticle &right) const;
G4int operator!=(const G4VShortLivedParticle &right) const;
G4bool operator==(const G4VShortLivedParticle &right) const;
G4bool operator!=(const G4VShortLivedParticle &right) const;
};
@@ -61,12 +61,12 @@ G4VShortLivedParticle::G4VShortLivedParticle(const G4String& aName,
G4VShortLivedParticle::~G4VShortLivedParticle() {}
G4int G4VShortLivedParticle::operator==(const G4VShortLivedParticle &right) const
G4bool G4VShortLivedParticle::operator==(const G4VShortLivedParticle &right) const
{
return (this->GetParticleName() == right.GetParticleName());
}
G4int G4VShortLivedParticle::operator!=(const G4VShortLivedParticle &right) const
G4bool G4VShortLivedParticle::operator!=(const G4VShortLivedParticle &right) const
{
return (this->GetParticleName() != right.GetParticleName());
}
@@ -53,10 +53,10 @@ class G4VParticlePropertyReporter
public:
// equality operators
G4int operator==(const G4VParticlePropertyReporter &right) const
G4bool operator==(const G4VParticlePropertyReporter &right) const
{ return (this == &right); }
G4int operator!=(const G4VParticlePropertyReporter &right) const
G4bool operator!=(const G4VParticlePropertyReporter &right) const
{ return (this != &right); }
public:
@@ -53,10 +53,10 @@ class G4VParticlePropertyRetriever
public:
// equality operators
G4int operator==(const G4VParticlePropertyRetriever &right) const
G4bool operator==(const G4VParticlePropertyRetriever &right) const
{ return (this == &right); }
G4int operator!=(const G4VParticlePropertyRetriever &right) const
G4bool operator!=(const G4VParticlePropertyRetriever &right) const
{ return (this != &right); }
public: