Import Geant4 8.3.0 source tree
This commit is contained in:
@@ -24,8 +24,8 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4LogicalVolumeStore.cc,v 1.17 2006/11/30 10:39:28 gcosmo Exp $
|
||||
// GEANT4 tag $Name: geant4-08-02 $
|
||||
// $Id: G4LogicalVolumeStore.cc,v 1.18 2007/04/10 10:13:50 gcosmo Exp $
|
||||
// GEANT4 tag $Name: geant4-08-03 $
|
||||
//
|
||||
// G4LogicalVolumeStore
|
||||
//
|
||||
@@ -152,6 +152,28 @@ void G4LogicalVolumeStore::DeRegister(G4LogicalVolume* pVolume)
|
||||
}
|
||||
}
|
||||
|
||||
// ***************************************************************************
|
||||
// Retrieve the first volume pointer in the container having that name
|
||||
// ***************************************************************************
|
||||
//
|
||||
G4LogicalVolume*
|
||||
G4LogicalVolumeStore::GetVolume(const G4String& name, G4bool verbose) const
|
||||
{
|
||||
for (iterator i=GetInstance()->begin(); i!=GetInstance()->end(); i++)
|
||||
{
|
||||
if ((*i)->GetName() == name) { return *i; }
|
||||
}
|
||||
if (verbose)
|
||||
{
|
||||
G4cerr << "ERROR - G4LogicalVolumeStore::GetVolume()" << G4endl
|
||||
<< " Volume " << name << " NOT found in store !" << G4endl
|
||||
<< " Returning NULL pointer." << G4endl;
|
||||
G4Exception("G4LogicalVolumeStore::GetVolume()", "InvalidQuery",
|
||||
JustWarning, "Volume NOT found in store !");
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
// ***************************************************************************
|
||||
// Return ptr to Store, setting if necessary
|
||||
// ***************************************************************************
|
||||
|
||||
@@ -24,8 +24,8 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4PhysicalVolumeStore.cc,v 1.18 2006/11/30 10:39:28 gcosmo Exp $
|
||||
// GEANT4 tag $Name: geant4-08-02 $
|
||||
// $Id: G4PhysicalVolumeStore.cc,v 1.19 2007/04/10 10:13:50 gcosmo Exp $
|
||||
// GEANT4 tag $Name: geant4-08-03 $
|
||||
//
|
||||
// G4PhysicalVolumeStore
|
||||
//
|
||||
@@ -166,6 +166,28 @@ void G4PhysicalVolumeStore::DeRegister(G4VPhysicalVolume* pVolume)
|
||||
}
|
||||
}
|
||||
|
||||
// ***************************************************************************
|
||||
// Retrieve the first volume pointer in the container having that name
|
||||
// ***************************************************************************
|
||||
//
|
||||
G4VPhysicalVolume*
|
||||
G4PhysicalVolumeStore::GetVolume(const G4String& name, G4bool verbose) const
|
||||
{
|
||||
for (iterator i=GetInstance()->begin(); i!=GetInstance()->end(); i++)
|
||||
{
|
||||
if ((*i)->GetName() == name) { return *i; }
|
||||
}
|
||||
if (verbose)
|
||||
{
|
||||
G4cerr << "ERROR - G4PhysicalVolumeStore::GetVolume()" << G4endl
|
||||
<< " Volume " << name << " NOT found in store !" << G4endl
|
||||
<< " Returning NULL pointer." << G4endl;
|
||||
G4Exception("G4PhysicalVolumeStore::GetVolume()", "InvalidQuery",
|
||||
JustWarning, "Volume NOT found in store !");
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
// ***************************************************************************
|
||||
// Return ptr to Store, setting if necessary
|
||||
// ***************************************************************************
|
||||
|
||||
@@ -24,8 +24,8 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4Region.cc,v 1.21 2006/07/17 08:36:47 asaim Exp $
|
||||
// GEANT4 tag $Name: geant4-08-02 $
|
||||
// $Id: G4Region.cc,v 1.22 2007/03/20 22:29:50 gcosmo Exp $
|
||||
// GEANT4 tag $Name: geant4-08-03 $
|
||||
//
|
||||
//
|
||||
// class G4Region Implementation
|
||||
@@ -239,8 +239,11 @@ void G4Region::RemoveRootLogicalVolume(G4LogicalVolume* lv)
|
||||
pos = std::find(fRootVolumes.begin(),fRootVolumes.end(),lv);
|
||||
if (pos != fRootVolumes.end())
|
||||
{
|
||||
if (fRootVolumes.size() != 1) // Avoid resetting flag for world since
|
||||
{ // volume may be already deleted !
|
||||
lv->SetRegionRootFlag(false);
|
||||
}
|
||||
fRootVolumes.erase(pos);
|
||||
lv->SetRegionRootFlag(false);
|
||||
}
|
||||
|
||||
// Scan recursively the tree of daugther volumes and reset regions
|
||||
|
||||
@@ -24,8 +24,8 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4RegionStore.cc,v 1.12 2006/11/30 10:39:28 gcosmo Exp $
|
||||
// GEANT4 tag $Name: geant4-08-02 $
|
||||
// $Id: G4RegionStore.cc,v 1.13 2007/04/10 10:13:50 gcosmo Exp $
|
||||
// GEANT4 tag $Name: geant4-08-03 $
|
||||
//
|
||||
// G4RegionStore
|
||||
//
|
||||
@@ -224,7 +224,10 @@ G4Region* G4RegionStore::GetRegion(const G4String& name, G4bool verbose) const
|
||||
if (verbose)
|
||||
{
|
||||
G4cerr << "ERROR - G4RegionStore::GetRegion()" << G4endl
|
||||
<< " Region " << name << " NOT found in store !" << G4endl;
|
||||
<< " Region " << name << " NOT found in store !" << G4endl
|
||||
<< " Returning NULL pointer." << G4endl;
|
||||
G4Exception("G4RegionStore::GetRegion()", "InvalidQuery",
|
||||
JustWarning, "Region NOT found in store !");
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -24,8 +24,8 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4SolidStore.cc,v 1.16 2006/11/30 10:39:28 gcosmo Exp $
|
||||
// GEANT4 tag $Name: geant4-08-02 $
|
||||
// $Id: G4SolidStore.cc,v 1.17 2007/04/10 10:13:50 gcosmo Exp $
|
||||
// GEANT4 tag $Name: geant4-08-03 $
|
||||
//
|
||||
// G4SolidStore
|
||||
//
|
||||
@@ -152,6 +152,27 @@ void G4SolidStore::DeRegister(G4VSolid* pSolid)
|
||||
}
|
||||
}
|
||||
|
||||
// ***************************************************************************
|
||||
// Retrieve the first solid pointer in the container having that name
|
||||
// ***************************************************************************
|
||||
//
|
||||
G4VSolid* G4SolidStore::GetSolid(const G4String& name, G4bool verbose) const
|
||||
{
|
||||
for (iterator i=GetInstance()->begin(); i!=GetInstance()->end(); i++)
|
||||
{
|
||||
if ((*i)->GetName() == name) { return *i; }
|
||||
}
|
||||
if (verbose)
|
||||
{
|
||||
G4cerr << "ERROR - G4SolidStore::GetSolid()" << G4endl
|
||||
<< " Solid " << name << " not found in store !" << G4endl
|
||||
<< " Returning NULL pointer." << G4endl;
|
||||
G4Exception("G4SolidStore::GetSolid()", "InvalidQuery",
|
||||
JustWarning, "Solid NOT found in store !");
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
// ***************************************************************************
|
||||
// Return ptr to Store, setting if necessary
|
||||
// ***************************************************************************
|
||||
|
||||
@@ -24,8 +24,8 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4VPhysicalVolume.cc,v 1.12 2006/09/18 14:03:25 gcosmo Exp $
|
||||
// GEANT4 tag $Name: geant4-08-02 $
|
||||
// $Id: G4VPhysicalVolume.cc,v 1.14 2007/04/11 08:00:12 gcosmo Exp $
|
||||
// GEANT4 tag $Name: geant4-08-03 $
|
||||
//
|
||||
//
|
||||
// class G4VPhysicalVolume Implementation
|
||||
@@ -95,7 +95,7 @@ G4RotationMatrix* G4VPhysicalVolume::GetObjectRotation() const
|
||||
// Only implemented for placed and parameterised volumes.
|
||||
// Not required for replicas.
|
||||
//
|
||||
G4bool G4VPhysicalVolume::CheckOverlaps(G4int)
|
||||
G4bool G4VPhysicalVolume::CheckOverlaps(G4int, G4double, G4bool)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user