Import Geant4 4.1.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-08 16:39:52 +02:00
parent 921d3b1cda
commit 330b82b769
4524 changed files with 178689 additions and 43575 deletions
+21 -2
View File
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4DataVector.cc,v 1.3 2001/11/29 18:59:35 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
// $Id: G4DataVector.cc,v 1.5 2002/05/30 11:56:40 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-01 $
//
//
// --------------------------------------------------------------
@@ -37,6 +37,25 @@
#include "G4DataVector.hh"
#include "g4std/iomanip"
G4DataVector::G4DataVector()
: G4std::vector<G4double>()
{
}
G4DataVector::G4DataVector(size_t capacity)
: G4std::vector<G4double>(capacity, 0.0)
{
}
G4DataVector::G4DataVector(size_t capacity, G4double value)
: G4std::vector<G4double>(capacity, value)
{
}
G4DataVector::~G4DataVector()
{
}
G4bool G4DataVector::Store(G4std::ofstream& fOut, G4bool ascii)
{
// Ascii mode
+3 -3
View File
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4Exception.cc,v 1.12 2001/10/11 14:04:12 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
// $Id: G4Exception.cc,v 1.13 2002/04/16 18:19:14 asaim Exp $
// GEANT4 tag $Name: geant4-04-01 $
//
//
// ----------------------------------------------------------------------
@@ -45,7 +45,7 @@ void G4Exception(const char* s)
{
G4cerr << s << G4endl;
}
if(G4StateManager::GetStateManager()->SetNewState(Abort)) {
if(G4StateManager::GetStateManager()->SetNewState(Abort,s)) {
G4cerr << G4endl << "*** G4Exception: Aborting execution ***" << G4endl;
abort();
} else {
@@ -22,7 +22,7 @@
//
//
// $Id: G4LPhysicsFreeVector.cc,v 1.8 2001/07/11 10:00:56 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
// GEANT4 tag $Name: geant4-04-01 $
//
//
// --------------------------------------------------------------------
+16 -2
View File
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4OrderedTable.cc,v 1.1 2001/09/17 08:17:58 kurasige Exp $
// GEANT4 tag $Name: geant4-04-00 $
// $Id: G4OrderedTable.cc,v 1.2 2002/04/19 07:10:32 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-01 $
//
//
// ------------------------------------------------------------
@@ -39,6 +39,20 @@
#include "g4std/iomanip"
G4OrderedTable::G4OrderedTable()
: G4std::vector<G4DataVector*>()
{
}
G4OrderedTable::G4OrderedTable(size_t capacity)
: G4std::vector<G4DataVector*>(capacity, (G4DataVector*)(0) )
{
}
G4OrderedTable::~G4OrderedTable()
{
}
G4bool G4OrderedTable::Store(const G4String& fileName,
G4bool ascii)
{
@@ -22,7 +22,7 @@
//
//
// $Id: G4PhysicsFreeVector.cc,v 1.8 2001/07/11 10:00:57 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
// GEANT4 tag $Name: geant4-04-01 $
//
//
//--------------------------------------------------------------------
@@ -22,7 +22,7 @@
//
//
// $Id: G4PhysicsLinearVector.cc,v 1.9 2001/07/11 10:00:57 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
// GEANT4 tag $Name: geant4-04-01 $
//
//
//--------------------------------------------------------------------
@@ -22,7 +22,7 @@
//
//
// $Id: G4PhysicsLnVector.cc,v 1.11 2001/07/11 10:00:57 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
// GEANT4 tag $Name: geant4-04-01 $
//
//
// --------------------------------------------------------------
@@ -22,7 +22,7 @@
//
//
// $Id: G4PhysicsLogVector.cc,v 1.9 2001/07/11 10:00:57 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
// GEANT4 tag $Name: geant4-04-01 $
//
//
// --------------------------------------------------------------
@@ -22,7 +22,7 @@
//
//
// $Id: G4PhysicsOrderedFreeVector.cc,v 1.8 2001/07/11 10:00:57 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
// GEANT4 tag $Name: geant4-04-01 $
//
////////////////////////////////////////////////////////////////////////
// PhysicsOrderedFreeVector Class Implementation
@@ -22,7 +22,7 @@
//
//
// $Id: G4PhysicsTable.cc,v 1.6 2001/07/11 10:00:58 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
// GEANT4 tag $Name: geant4-04-01 $
//
//
// ------------------------------------------------------------
@@ -22,7 +22,7 @@
//
//
// $Id: G4PhysicsVector.cc,v 1.14 2001/11/29 18:59:35 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
// GEANT4 tag $Name: geant4-04-01 $
//
//
// --------------------------------------------------------------
+10 -3
View File
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4StateManager.cc,v 1.5 2001/07/18 17:59:23 asaim Exp $
// GEANT4 tag $Name: geant4-04-00 $
// $Id: G4StateManager.cc,v 1.6 2002/04/16 18:19:14 asaim Exp $
// GEANT4 tag $Name: geant4-04-01 $
//
//
// ------------------------------------------------------------
@@ -41,7 +41,8 @@ G4StateManager::G4StateManager()
: theCurrentState(PreInit),
thePreviousState(PreInit),
theBottomDependent(0),
suppressAbortion(0)
suppressAbortion(0),
msgptr(0)
{
}
@@ -159,11 +160,16 @@ G4StateManager::GetPreviousState() const
G4bool
G4StateManager::SetNewState(G4ApplicationState requestedState)
{ return SetNewState(requestedState,0); }
G4bool
G4StateManager::SetNewState(G4ApplicationState requestedState, const char* msg)
{
if(requestedState==Abort && suppressAbortion>0) {
if(suppressAbortion==2) return false;
if(theCurrentState==EventProc) return false;
}
msgptr = msg;
size_t i=0;
G4bool ack = true;
G4ApplicationState savedState = thePreviousState;
@@ -184,6 +190,7 @@ G4StateManager::SetNewState(G4ApplicationState requestedState)
theCurrentState = thePreviousState;
thePreviousState = savedState;
}
msgptr = 0;
return ack;
}
+3 -3
View File
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4Timer.cc,v 1.9 2001/07/11 10:00:59 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
// $Id: G4Timer.cc,v 1.10 2002/01/17 10:49:02 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-01 $
//
//
// ----------------------------------------------------------------------
@@ -68,7 +68,7 @@ void G4Exception(const char* s=0);
GetSystemTime( &realtime );
SystemTimeToFileTime( &realtime, &rt ); // get real time in 10^-9 sec
if( t != NULL ){
if( t != 0 ){
GetProcessTimes( GetCurrentProcess(), &ct, &et, &st, &ut);// get process time in 10^-9 sec
t->tms_utime = t->tms_cutime = filetime2msec(&ut);
t->tms_stime = t->tms_cstime = filetime2msec(&st);
+7 -6
View File
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4UnitsTable.cc,v 1.15 2001/07/11 10:00:59 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
// $Id: G4UnitsTable.cc,v 1.16 2002/05/06 12:06:48 maire Exp $
// GEANT4 tag $Name: geant4-04-01 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//
@@ -31,6 +31,7 @@
// 13-10-98: units and symbols printed in fixed length, M.Maire
// 01-03-01: parsec, M.Maire
// 06-03-01: migration to STL vectors, G.Cosmo
// 06-05-02: BestUnit operator<< flux instead of G4cout (mma)
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
@@ -422,14 +423,14 @@ G4std::ostream& operator<<(G4std::ostream& flux, G4BestUnit a)
{flux << a.Value[j]/(List[index]->GetValue()) << " ";}
#ifdef G4USE_STD_NAMESPACE
std::ios::fmtflags oldform = G4cout.flags();
std::ios::fmtflags oldform = flux.flags();
#else
G4long oldform = G4cout.flags();
G4long oldform = flux.flags();
#endif
G4cout.setf(G4std::ios::left,G4std::ios::adjustfield);
flux.setf(G4std::ios::left,G4std::ios::adjustfield);
flux << G4std::setw(len) << List[index]->GetSymbol();
G4cout.flags(oldform);
flux.flags(oldform);
return flux;
}
@@ -22,7 +22,7 @@
//
//
// $Id: G4VStateDependent.cc,v 1.3 2001/07/11 10:00:59 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
// GEANT4 tag $Name: geant4-04-01 $
//
//
// ------------------------------------------------------------
+1 -1
View File
@@ -22,7 +22,7 @@
//
//
// $Id: G4ios.cc,v 1.5 2001/07/11 10:00:59 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
// GEANT4 tag $Name: geant4-04-01 $
//
//
// --------------------------------------------------------------