Import Geant4 10.0.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-10 11:51:14 +02:00
parent e2d2f9810a
commit 286caacf06
12421 changed files with 730077 additions and 502383 deletions
@@ -24,20 +24,20 @@
// ********************************************************************
//
//
// $Id$
// $Id: G4HCofThisEvent.cc 67992 2013-03-13 10:59:57Z gcosmo $
//
#include "G4HCofThisEvent.hh"
G4Allocator<G4HCofThisEvent> anHCoTHAllocator;
G4ThreadLocal G4Allocator<G4HCofThisEvent> *anHCoTHAllocator_G4MT_TLS_ = 0;
G4HCofThisEvent::G4HCofThisEvent()
{
{ if (!anHCoTHAllocator_G4MT_TLS_) anHCoTHAllocator_G4MT_TLS_ = new G4Allocator<G4HCofThisEvent> ;
HC = new std::vector<G4VHitsCollection*>;
}
G4HCofThisEvent::G4HCofThisEvent(G4int cap)
{
{ if (!anHCoTHAllocator_G4MT_TLS_) anHCoTHAllocator_G4MT_TLS_ = new G4Allocator<G4HCofThisEvent> ;
HC = new std::vector<G4VHitsCollection*>;
for(G4int i=0;i<cap;i++)
{
@@ -46,7 +46,7 @@ G4HCofThisEvent::G4HCofThisEvent(G4int cap)
}
G4HCofThisEvent::~G4HCofThisEvent()
{
{ if (!anHCoTHAllocator_G4MT_TLS_) anHCoTHAllocator_G4MT_TLS_ = new G4Allocator<G4HCofThisEvent> ;
//HC->clearAndDestroy();
for(size_t i=0;i<HC->size();i++)
{ delete (*HC)[i]; }
@@ -55,7 +55,7 @@ G4HCofThisEvent::~G4HCofThisEvent()
}
void G4HCofThisEvent::AddHitsCollection(G4int HCID,G4VHitsCollection * aHC)
{
{ if (!anHCoTHAllocator_G4MT_TLS_) anHCoTHAllocator_G4MT_TLS_ = new G4Allocator<G4HCofThisEvent> ;
if(HCID>=0 && HCID<G4int(HC->size()))
{ (*HC)[HCID] = aHC; }
}
@@ -24,23 +24,23 @@
// ********************************************************************
//
//
// $Id$
// $Id: G4THitsCollection.cc 67992 2013-03-13 10:59:57Z gcosmo $
//
#include "G4THitsCollection.hh"
G4Allocator<G4HitsCollection> anHCAllocator;
G4ThreadLocal G4Allocator<G4HitsCollection> *anHCAllocator_G4MT_TLS_ = 0;
G4HitsCollection::G4HitsCollection() : theCollection((void*)0)
{;}
{ if (!anHCAllocator_G4MT_TLS_) anHCAllocator_G4MT_TLS_ = new G4Allocator<G4HitsCollection> ;;}
G4HitsCollection::G4HitsCollection(G4String detName,G4String colNam)
: G4VHitsCollection(detName,colNam), theCollection((void*)0)
{;}
{ if (!anHCAllocator_G4MT_TLS_) anHCAllocator_G4MT_TLS_ = new G4Allocator<G4HitsCollection> ;;}
G4HitsCollection::~G4HitsCollection()
{;}
{ if (!anHCAllocator_G4MT_TLS_) anHCAllocator_G4MT_TLS_ = new G4Allocator<G4HitsCollection> ;;}
int G4HitsCollection::operator==(const G4HitsCollection &right) const
{ return (collectionName==right.collectionName); }
{ if (!anHCAllocator_G4MT_TLS_) anHCAllocator_G4MT_TLS_ = new G4Allocator<G4HitsCollection> ; return (collectionName==right.collectionName); }
+1 -1
View File
@@ -24,7 +24,7 @@
// ********************************************************************
//
//
// $Id$
// $Id: G4VHit.cc 67992 2013-03-13 10:59:57Z gcosmo $
//
// G4VHit
@@ -24,7 +24,7 @@
// ********************************************************************
//
//
// $Id$
// $Id: G4VHitsCollection.cc 67992 2013-03-13 10:59:57Z gcosmo $
//
// G4VHitsCollection