ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
DicomRun Class Reference

#include <geant4/tree/geant4-10.6-release/examples/extended/medical/DICOM/include/DicomRun.hh>

+ Inheritance diagram for DicomRun:
+ Collaboration diagram for DicomRun:

Public Member Functions

 DicomRun ()
 
 DicomRun (const std::vector< G4String > mfdName)
 
virtual ~DicomRun ()
 
virtual void RecordEvent (const G4Event *)
 
size_t GetNumberOfHitsMap () const
 
G4THitsMap< G4double > * GetHitsMap (G4int i) const
 
G4THitsMap< G4double > * GetHitsMap (const G4String &detName, const G4String &colName) const
 
G4THitsMap< G4double > * GetHitsMap (const G4String &fullName) const
 
void ConstructMFD (const std::vector< G4String > &)
 
virtual void Merge (const G4Run *)
 
- Public Member Functions inherited from G4Run
 G4Run ()
 
virtual ~G4Run ()
 
G4int GetRunID () const
 
G4int GetNumberOfEvent () const
 
G4int GetNumberOfEventToBeProcessed () const
 
const G4HCtableGetHCtable () const
 
const G4DCtableGetDCtable () const
 
const G4StringGetRandomNumberStatus () const
 
void SetRunID (G4int id)
 
void SetNumberOfEventToBeProcessed (G4int n_ev)
 
void SetHCtable (G4HCtable *HCtbl)
 
void SetDCtable (G4DCtable *DCtbl)
 
void SetRandomNumberStatus (G4String &st)
 
void StoreEvent (G4Event *evt)
 
const std::vector< const
G4Event * > * 
GetEventVector () const
 

Private Attributes

std::vector< G4StringfCollName
 
std::vector< G4intfCollID
 
std::vector< G4THitsMap
< G4double > * > 
fRunMap
 

Additional Inherited Members

- Protected Attributes inherited from G4Run
G4int runID
 
G4int numberOfEvent
 
G4int numberOfEventToBeProcessed
 
G4HCtableHCtable
 
G4DCtableDCtable
 
G4String randomNumberStatus
 
std::vector< const G4Event * > * eventVector
 

Detailed Description

DicomRun class

Example implementation for multi-functional-detector and primitive scorer. This DicomRun class has collections which accumulate a event information into a run information.

Definition at line 49 of file DicomRun.hh.

View newest version in sPHENIX GitHub at line 49 of file DicomRun.hh

Constructor & Destructor Documentation

DicomRun::DicomRun ( )

(Description) DicomRun Class is for accumulating scored quantities which is scored using G4MutiFunctionalDetector and G4VPrimitiveScorer. Accumulation is done using G4THitsMap object.

The constructor DicomRun(const std::vector<G4String> mfdName) needs a vector filled with MultiFunctionalDetector names which was assigned at instantiation of MultiFunctionalDetector(MFD). Then DicomRun constructor automatically scans primitive scorers in the MFD, and obtains collectionIDs of all collections associated to those primitive scorers. Futhermore, the G4THitsMap objects for accumulating during a RUN are automatically created too. (*) Collection Name is same as primitive scorer name.

The resultant information is kept inside DicomRun objects as data members. std::vector<G4String> fCollName; // Collection Name, std::vector<G4int> fCollID; // Collection ID, std::vector<G4THitsMap<G4double>*> fRunMap; // HitsMap for RUN.

The resualtant HitsMap objects are obtain using access method, GetHitsMap(..).

Definition at line 66 of file DicomRun.cc.

View newest version in sPHENIX GitHub at line 66 of file DicomRun.cc

DicomRun::DicomRun ( const std::vector< G4String mfdName)

Definition at line 74 of file DicomRun.cc.

View newest version in sPHENIX GitHub at line 74 of file DicomRun.cc

References ConstructMFD().

+ Here is the call graph for this function:

DicomRun::~DicomRun ( )
virtual

Definition at line 83 of file DicomRun.cc.

View newest version in sPHENIX GitHub at line 83 of file DicomRun.cc

References fCollID, fCollName, and fRunMap.

Member Function Documentation

void DicomRun::ConstructMFD ( const std::vector< G4String > &  mfdName)

Definition at line 100 of file DicomRun.cc.

View newest version in sPHENIX GitHub at line 100 of file DicomRun.cc

References fCollID, fCollName, G4SDManager::FindSensitiveDetector(), fRunMap, G4cout, G4endl, G4SDManager::GetCollectionID(), G4VPrimitiveScorer::GetName(), G4MultiFunctionalDetector::GetNumberOfPrimitives(), G4MultiFunctionalDetector::GetPrimitive(), and G4SDManager::GetSDMpointer().

Referenced by Dicom2Run::ConstructMFD(), and DicomRun().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

G4THitsMap<G4double>* DicomRun::GetHitsMap ( G4int  i) const
inline

Definition at line 71 of file DicomRun.hh.

View newest version in sPHENIX GitHub at line 71 of file DicomRun.hh

References fRunMap.

Referenced by DicomRunAction::EndOfRunAction(), and GetHitsMap().

+ Here is the caller graph for this function:

G4THitsMap< G4double > * DicomRun::GetHitsMap ( const G4String detName,
const G4String colName 
) const

Definition at line 224 of file DicomRun.cc.

View newest version in sPHENIX GitHub at line 224 of file DicomRun.cc

References GetHitsMap().

+ Here is the call graph for this function:

G4THitsMap< G4double > * DicomRun::GetHitsMap ( const G4String fullName) const

Definition at line 235 of file DicomRun.cc.

View newest version in sPHENIX GitHub at line 235 of file DicomRun.cc

References fCollName, fRunMap, G4Exception(), and JustWarning.

+ Here is the call graph for this function:

size_t DicomRun::GetNumberOfHitsMap ( ) const
inline

Definition at line 67 of file DicomRun.hh.

View newest version in sPHENIX GitHub at line 67 of file DicomRun.hh

References fRunMap.

void DicomRun::Merge ( const G4Run aRun)
virtual

Reimplemented from G4Run.

Reimplemented in Dicom2Run.

Definition at line 202 of file DicomRun.cc.

View newest version in sPHENIX GitHub at line 202 of file DicomRun.cc

References Copy(), fCollID, fCollName, fRunMap, and G4Run::Merge().

Referenced by Dicom2Run::Merge().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void DicomRun::RecordEvent ( const G4Event aEvent)
virtual

Reimplemented from G4Run.

Reimplemented in Dicom2Run.

Definition at line 157 of file DicomRun.cc.

View newest version in sPHENIX GitHub at line 157 of file DicomRun.cc

References fCollID, fRunMap, G4cout, G4endl, G4HCofThisEvent::GetHC(), G4Event::GetHCofThisEvent(), and G4Run::RecordEvent().

Referenced by Dicom2Run::RecordEvent().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Member Data Documentation

std::vector<G4int> DicomRun::fCollID
private

Definition at line 83 of file DicomRun.hh.

View newest version in sPHENIX GitHub at line 83 of file DicomRun.hh

Referenced by ConstructMFD(), Merge(), RecordEvent(), and ~DicomRun().

std::vector<G4String> DicomRun::fCollName
private

Definition at line 82 of file DicomRun.hh.

View newest version in sPHENIX GitHub at line 82 of file DicomRun.hh

Referenced by ConstructMFD(), GetHitsMap(), Merge(), and ~DicomRun().

std::vector<G4THitsMap<G4double>*> DicomRun::fRunMap
private

Definition at line 84 of file DicomRun.hh.

View newest version in sPHENIX GitHub at line 84 of file DicomRun.hh

Referenced by ConstructMFD(), GetHitsMap(), GetNumberOfHitsMap(), Merge(), RecordEvent(), and ~DicomRun().


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