Geant4  10.02.p03
G4VPrimitiveScorer Class Referenceabstract

#include <G4VPrimitiveScorer.hh>

Inheritance diagram for G4VPrimitiveScorer:
Collaboration diagram for G4VPrimitiveScorer:

Public Member Functions

 G4VPrimitiveScorer (G4String name, G4int depth=0)
 
virtual ~G4VPrimitiveScorer ()
 
G4int GetCollectionID (G4int)
 
virtual void Initialize (G4HCofThisEvent *)
 
virtual void EndOfEvent (G4HCofThisEvent *)
 
virtual void clear ()
 
virtual void DrawAll ()
 
virtual void PrintAll ()
 
void SetUnit (const G4String &unit)
 
const G4StringGetUnit () const
 
G4double GetUnitValue () const
 
void SetMultiFunctionalDetector (G4MultiFunctionalDetector *d)
 
G4MultiFunctionalDetectorGetMultiFunctionalDetector () const
 
G4String GetName () const
 
void SetFilter (G4VSDFilter *f)
 
G4VSDFilterGetFilter () const
 
void SetVerboseLevel (G4int vl)
 
G4int GetVerboseLevel () const
 
void SetNijk (G4int i, G4int j, G4int k)
 

Protected Member Functions

virtual G4bool ProcessHits (G4Step *, G4TouchableHistory *)=0
 
virtual G4int GetIndex (G4Step *)
 
void CheckAndSetUnit (const G4String &unit, const G4String &category)
 

Protected Attributes

G4String primitiveName
 
G4MultiFunctionalDetectordetector
 
G4VSDFilterfilter
 
G4int verboseLevel
 
G4int indexDepth
 
G4String unitName
 
G4double unitValue
 
G4int fNi
 
G4int fNj
 
G4int fNk
 

Private Member Functions

G4bool HitPrimitive (G4Step *aStep, G4TouchableHistory *ROhis)
 

Friends

class G4MultiFunctionalDetector
 

Detailed Description

Definition at line 50 of file G4VPrimitiveScorer.hh.

Constructor & Destructor Documentation

◆ G4VPrimitiveScorer()

G4VPrimitiveScorer::G4VPrimitiveScorer ( G4String  name,
G4int  depth = 0 
)

Definition at line 37 of file G4VPrimitiveScorer.cc.

◆ ~G4VPrimitiveScorer()

G4VPrimitiveScorer::~G4VPrimitiveScorer ( )
virtual

Definition at line 42 of file G4VPrimitiveScorer.cc.

43 {;}

Member Function Documentation

◆ CheckAndSetUnit()

void G4VPrimitiveScorer::CheckAndSetUnit ( const G4String unit,
const G4String category 
)
protected

Definition at line 76 of file G4VPrimitiveScorer.cc.

77  {
78  if ( G4UnitDefinition::GetCategory(unit) == category){
79  unitName = unit;
81  } else {
82  G4String msg = "Invalid unit ["+unit+"] (Current unit is [" +GetUnit()+"] ) requested for " + GetName();
83  G4Exception("G4VPrimitiveScorer::CheckAndSetUnit","Det0151",JustWarning,msg);
84  }
85 }
G4String GetName() const
static G4double GetValueOf(const G4String &)
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *comments)
Definition: G4Exception.cc:41
static G4String GetCategory(const G4String &)
const G4String & GetUnit() const
Here is the call graph for this function:
Here is the caller graph for this function:

◆ clear()

◆ DrawAll()

◆ EndOfEvent()

◆ GetCollectionID()

G4int G4VPrimitiveScorer::GetCollectionID ( G4int  )

Definition at line 45 of file G4VPrimitiveScorer.cc.

46 {
47  if(detector)
50  else
51  return -1;
52 }
G4int GetCollectionID(G4String colName)
Definition: G4SDManager.cc:135
static G4SDManager * GetSDMpointer()
Definition: G4SDManager.cc:40
G4MultiFunctionalDetector * detector
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetFilter()

G4VSDFilter* G4VPrimitiveScorer::GetFilter ( ) const
inline

Definition at line 107 of file G4VPrimitiveScorer.hh.

108  { return filter; }
Here is the caller graph for this function:

◆ GetIndex()

G4int G4VPrimitiveScorer::GetIndex ( G4Step *  aStep)
protectedvirtual

Reimplemented in CexmcTrackPoints, CexmcSimpleEnergyDeposit, G4PSFlatSurfaceFlux3D, G4PSSphereSurfaceCurrent3D, G4PSSphereSurfaceFlux3D, RE02PSFlatSurfaceFlux, G4PSCylinderSurfaceCurrent3D, G4PSCylinderSurfaceFlux3D, G4PSFlatSurfaceCurrent3D, CexmcEnergyDepositInLeftRightSet, CexmcTrackPointsInLeftRightSet, RE02PSFlatSurfaceCurrent, G4PSCellFlux3D, CexmcEnergyDepositInCalorimeter, CexmcTrackPointsInCalorimeter, RE02PSCellFlux, G4PSPassageCellFlux3D, G4PSPassageTrackLength3D, G4PSTrackLength3D, G4PSCellCharge3D, G4PSMinKinEAtGeneration3D, RE02PSPassageCellFlux, G4PSDoseDeposit3D, G4PSTrackCounter3D, G4PSEnergyDeposit3D, G4PSNofCollision3D, G4PSPassageCellCurrent3D, G4PSPopulation3D, G4PSStepChecker3D, G4PSTermination3D, G4PSNofStep3D, RE02PSNofStep, RE02PSEnergyDeposit, and G4PSNofSecondary3D.

Definition at line 69 of file G4VPrimitiveScorer.cc.

70 {
71  G4StepPoint* preStep = aStep->GetPreStepPoint();
72  G4TouchableHistory* th = (G4TouchableHistory*)(preStep->GetTouchable());
73  return th->GetReplicaNumber(indexDepth);
74 }
G4int GetReplicaNumber(G4int depth=0) const
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetMultiFunctionalDetector()

G4MultiFunctionalDetector* G4VPrimitiveScorer::GetMultiFunctionalDetector ( ) const
inline

Definition at line 101 of file G4VPrimitiveScorer.hh.

102  { return detector; }
G4MultiFunctionalDetector * detector
Here is the caller graph for this function:

◆ GetName()

G4String G4VPrimitiveScorer::GetName ( void  ) const
inline

Definition at line 103 of file G4VPrimitiveScorer.hh.

104  { return primitiveName; }

◆ GetUnit()

const G4String& G4VPrimitiveScorer::GetUnit ( ) const
inline

Definition at line 82 of file G4VPrimitiveScorer.hh.

82 { return unitName; }
Here is the caller graph for this function:

◆ GetUnitValue()

G4double G4VPrimitiveScorer::GetUnitValue ( ) const
inline

Definition at line 83 of file G4VPrimitiveScorer.hh.

83 { return unitValue; }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetVerboseLevel()

G4int G4VPrimitiveScorer::GetVerboseLevel ( ) const
inline

Definition at line 111 of file G4VPrimitiveScorer.hh.

112  { return verboseLevel; }
Here is the caller graph for this function:

◆ HitPrimitive()

G4bool G4VPrimitiveScorer::HitPrimitive ( G4Step *  aStep,
G4TouchableHistory ROhis 
)
inlineprivate

Definition at line 115 of file G4VPrimitiveScorer.hh.

116  {
117  if(filter)
118  { if(!(filter->Accept(aStep))) return false; }
119  return ProcessHits(aStep,ROhis);
120  }
virtual G4bool ProcessHits(G4Step *, G4TouchableHistory *)=0
virtual G4bool Accept(const G4Step *) const =0
Here is the call graph for this function:

◆ Initialize()

◆ PrintAll()

◆ ProcessHits()

◆ SetFilter()

void G4VPrimitiveScorer::SetFilter ( G4VSDFilter f)
inline

Definition at line 105 of file G4VPrimitiveScorer.hh.

106  { filter = f; }
Here is the caller graph for this function:

◆ SetMultiFunctionalDetector()

void G4VPrimitiveScorer::SetMultiFunctionalDetector ( G4MultiFunctionalDetector d)
inline

Definition at line 99 of file G4VPrimitiveScorer.hh.

100  { detector = d; }
Float_t d
G4MultiFunctionalDetector * detector
Here is the caller graph for this function:

◆ SetNijk()

void G4VPrimitiveScorer::SetNijk ( G4int  i,
G4int  j,
G4int  k 
)
inline

Definition at line 125 of file G4VPrimitiveScorer.hh.

Here is the caller graph for this function:

◆ SetUnit()

void G4VPrimitiveScorer::SetUnit ( const G4String unit)
inline

Definition at line 81 of file G4VPrimitiveScorer.hh.

81 { unitName = unit; }
Here is the caller graph for this function:

◆ SetVerboseLevel()

void G4VPrimitiveScorer::SetVerboseLevel ( G4int  vl)
inline

Definition at line 109 of file G4VPrimitiveScorer.hh.

110  { verboseLevel = vl; }
Here is the caller graph for this function:

Friends And Related Function Documentation

◆ G4MultiFunctionalDetector

friend class G4MultiFunctionalDetector
friend

Definition at line 52 of file G4VPrimitiveScorer.hh.

Member Data Documentation

◆ detector

G4MultiFunctionalDetector* G4VPrimitiveScorer::detector
protected

Definition at line 90 of file G4VPrimitiveScorer.hh.

◆ filter

G4VSDFilter* G4VPrimitiveScorer::filter
protected

Definition at line 91 of file G4VPrimitiveScorer.hh.

◆ fNi

G4int G4VPrimitiveScorer::fNi
protected

Definition at line 123 of file G4VPrimitiveScorer.hh.

◆ fNj

G4int G4VPrimitiveScorer::fNj
protected

Definition at line 123 of file G4VPrimitiveScorer.hh.

◆ fNk

G4int G4VPrimitiveScorer::fNk
protected

Definition at line 123 of file G4VPrimitiveScorer.hh.

◆ indexDepth

G4int G4VPrimitiveScorer::indexDepth
protected

Definition at line 93 of file G4VPrimitiveScorer.hh.

◆ primitiveName

G4String G4VPrimitiveScorer::primitiveName
protected

Definition at line 89 of file G4VPrimitiveScorer.hh.

◆ unitName

G4String G4VPrimitiveScorer::unitName
protected

Definition at line 94 of file G4VPrimitiveScorer.hh.

◆ unitValue

G4double G4VPrimitiveScorer::unitValue
protected

Definition at line 95 of file G4VPrimitiveScorer.hh.

◆ verboseLevel

G4int G4VPrimitiveScorer::verboseLevel
protected

Definition at line 92 of file G4VPrimitiveScorer.hh.


The documentation for this class was generated from the following files: