Geant4 11.3.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4VHitsCollection Class Reference

#include <G4VHitsCollection.hh>

+ Inheritance diagram for G4VHitsCollection:

Public Member Functions

 G4VHitsCollection ()=default
 
 G4VHitsCollection (const G4String &detName, const G4String &colNam)
 
virtual ~G4VHitsCollection ()=default
 
G4bool operator== (const G4VHitsCollection &right) const
 
virtual void DrawAllHits ()
 
virtual void PrintAllHits ()
 
const G4StringGetName () const
 
const G4StringGetSDname () const
 
void SetColID (G4int i)
 
G4int GetColID () const
 
virtual G4VHitGetHit (std::size_t) const
 
virtual std::size_t GetSize () const
 

Protected Attributes

G4String collectionName = "Unknown"
 
G4String SDname = "Unknown"
 
G4int colID = -1
 

Detailed Description

Definition at line 45 of file G4VHitsCollection.hh.

Constructor & Destructor Documentation

◆ G4VHitsCollection() [1/2]

G4VHitsCollection::G4VHitsCollection ( )
default

Referenced by operator==(), and ~G4VHitsCollection().

◆ G4VHitsCollection() [2/2]

G4VHitsCollection::G4VHitsCollection ( const G4String & detName,
const G4String & colNam )

Definition at line 31 of file G4VHitsCollection.cc.

32 : collectionName(colNam), SDname(detName), colID(-1)
33{}

◆ ~G4VHitsCollection()

virtual G4VHitsCollection::~G4VHitsCollection ( )
virtualdefault

Member Function Documentation

◆ DrawAllHits()

◆ GetColID()

G4int G4VHitsCollection::GetColID ( ) const
inline

Definition at line 60 of file G4VHitsCollection.hh.

60{ return colID; }

◆ GetHit()

◆ GetName()

const G4String & G4VHitsCollection::GetName ( ) const
inline

Definition at line 57 of file G4VHitsCollection.hh.

57{ return collectionName; }

Referenced by G4SDManager::GetCollectionID().

◆ GetSDname()

const G4String & G4VHitsCollection::GetSDname ( ) const
inline

Definition at line 58 of file G4VHitsCollection.hh.

58{ return SDname; }

Referenced by G4SDManager::GetCollectionID().

◆ GetSize()

◆ operator==()

G4bool G4VHitsCollection::operator== ( const G4VHitsCollection & right) const

Definition at line 35 of file G4VHitsCollection.cc.

36{
37 return ((collectionName == right.collectionName) && (SDname == right.SDname));
38}

◆ PrintAllHits()

◆ SetColID()

void G4VHitsCollection::SetColID ( G4int i)
inline

Definition at line 59 of file G4VHitsCollection.hh.

59{ colID = i; }

Referenced by G4HCofThisEvent::AddHitsCollection().

Member Data Documentation

◆ colID

G4int G4VHitsCollection::colID = -1
protected

Definition at line 74 of file G4VHitsCollection.hh.

Referenced by G4VHitsCollection(), GetColID(), and SetColID().

◆ collectionName

◆ SDname

G4String G4VHitsCollection::SDname = "Unknown"
protected

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