Import Geant4 5.0.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-08 16:57:27 +02:00
parent 330b82b769
commit 37fff30d2e
5733 changed files with 263867 additions and 74574 deletions
@@ -22,7 +22,7 @@
//
//
// $Id: G4HCofThisEvent.hh,v 1.7 2001/07/13 15:00:17 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-01 $
// GEANT4 tag $Name: geant4-05-00 $
//
#ifndef G4HCofThisEvent_h
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4THitsCollection.hh,v 1.9 2001/07/13 15:00:17 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-01 $
// $Id: G4THitsCollection.hh,v 1.11 2002/10/18 14:36:11 asaim Exp $
// GEANT4 tag $Name: geant4-05-00 $
//
#ifndef G4THitsCollection_h
@@ -101,6 +101,12 @@ template <class T> class G4THitsCollection : public G4HitsCollection
}
// Returns the number of hit objects stored in this collection
public:
virtual G4VHit* GetHit(size_t i) const
{ return (*((G4std::vector<T*>*)theCollection))[i]; }
virtual size_t GetSize() const
{ return ((G4std::vector<T*>*)theCollection)->size(); }
};
template <class T> inline void* G4THitsCollection<T>::operator new(size_t)
+23 -3
View File
@@ -21,14 +21,19 @@
// ********************************************************************
//
//
// $Id: G4VHit.hh,v 1.6 2001/07/13 15:00:17 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-01 $
// $Id: G4VHit.hh,v 1.9 2002/10/28 11:08:48 johna Exp $
// GEANT4 tag $Name: geant4-05-00 $
//
#ifndef G4VHit_h
#define G4VHit_h 1
#include "globals.hh"
#include "g4std/vector"
#include "g4std/map"
class G4AttDef;
class G4AttValue;
// class description:
//
@@ -50,7 +55,22 @@ class G4VHit
virtual void Draw();
virtual void Print();
virtual const G4std::map<G4String,G4AttDef>* GetAttDefs() const
{ return 0; }
// If implemented by a derived class, returns a pointer to a map
// of attribute definitions for the attribute values below. The
// user must test the validity of this pointer. See
// G4Trajectory for an example of a concrete implementation of
// this method.
virtual const G4std::vector<G4AttValue>* CreateAttValues() const
{ return 0; }
// If implemented by a derived class, returns a pointer to a
// list of attribute values suitable, e.g., for picking. Each
// must refer to an attribute definition in the above map; its
// name is the key. The user must test the validity of this
// pointer and delete the list after use. See G4Trajectory for
// an example of a concrete implementation of this method.
};
#endif
@@ -21,13 +21,14 @@
// ********************************************************************
//
//
// $Id: G4VHitsCollection.hh,v 1.6 2001/07/13 15:00:18 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-01 $
// $Id: G4VHitsCollection.hh,v 1.10 2002/10/30 16:20:06 asaim Exp $
// GEANT4 tag $Name: geant4-05-00 $
//
#ifndef G4VHitsCollection_h
#define G4VHitsCollection_h 1
class G4VHit;
#include "globals.hh"
// class description:
@@ -61,6 +62,14 @@ class G4VHitsCollection
{ return collectionName; }
inline G4String GetSDname()
{ return SDname; }
public:
// GetHit and GetSize are given a default implementation here so
// that the template G4THitsCollection can be used, but they
// are re-implemented G4THitsCollection.
virtual G4VHit* GetHit(size_t i) const { return 0; }
virtual size_t GetSize() const { return 0; };
};
#endif