DD4hep  1.30.0
Detector Description Toolkit for High Energy Physics
Public Types | Public Member Functions | Private Attributes | List of all members
dd4hep::sim::Geant4PrimaryMap Class Reference

Data structure to map primaries to particles. More...

#include <Geant4Primary.h>

Public Types

typedef std::map< const G4PrimaryParticle *, Geant4Particle * > Primaries
 

Public Member Functions

 Geant4PrimaryMap ()=default
 not persistent More...
 
virtual ~Geant4PrimaryMap ()
 Default destructor. More...
 
void insert (G4PrimaryParticle *g4_particle, Geant4Particle *particle)
 Add a new object pair (G4 primary particle, DDG4 particle) into the maps. More...
 
Geant4Particleget (const G4PrimaryParticle *particle)
 Access DDG4 particle by G4 primary particle. More...
 
const Geant4Particleget (const G4PrimaryParticle *particle) const
 Access DDG4 particle by G4 primary particle (const) More...
 
Primariesprimaries ()
 Access primary map directly. More...
 
const Primariesprimaries () const
 Access primary map directly (const) More...
 

Private Attributes

Primaries m_primaryMap
 Mapping of primary particles of this event. More...
 

Detailed Description

Data structure to map primaries to particles.

This data structure is added to the Geant4Event data extensions by the Geant4GenerationInit action.

Author
M.Frank
Version
1.0

Definition at line 64 of file Geant4Primary.h.

Member Typedef Documentation

◆ Primaries

typedef std::map<const G4PrimaryParticle*,Geant4Particle*> dd4hep::sim::Geant4PrimaryMap::Primaries

Definition at line 66 of file Geant4Primary.h.

Constructor & Destructor Documentation

◆ Geant4PrimaryMap()

dd4hep::sim::Geant4PrimaryMap::Geant4PrimaryMap ( )
default

not persistent

Default constructor

◆ ~Geant4PrimaryMap()

Geant4PrimaryMap::~Geant4PrimaryMap ( )
virtual

Default destructor.

Definition at line 34 of file Geant4Primary.cpp.

Member Function Documentation

◆ get() [1/2]

Geant4Particle * Geant4PrimaryMap::get ( const G4PrimaryParticle *  particle)

Access DDG4 particle by G4 primary particle.

Definition at line 44 of file Geant4Primary.cpp.

◆ get() [2/2]

const Geant4Particle * Geant4PrimaryMap::get ( const G4PrimaryParticle *  particle) const

Access DDG4 particle by G4 primary particle (const)

Definition at line 50 of file Geant4Primary.cpp.

◆ insert()

void Geant4PrimaryMap::insert ( G4PrimaryParticle *  g4_particle,
Geant4Particle particle 
)

Add a new object pair (G4 primary particle, DDG4 particle) into the maps.

Definition at line 39 of file Geant4Primary.cpp.

◆ primaries() [1/2]

Primaries& dd4hep::sim::Geant4PrimaryMap::primaries ( )
inline

Access primary map directly.

Definition at line 83 of file Geant4Primary.h.

◆ primaries() [2/2]

const Primaries& dd4hep::sim::Geant4PrimaryMap::primaries ( ) const
inline

Access primary map directly (const)

Definition at line 85 of file Geant4Primary.h.

Member Data Documentation

◆ m_primaryMap

Primaries dd4hep::sim::Geant4PrimaryMap::m_primaryMap
private

Mapping of primary particles of this event.

Definition at line 69 of file Geant4Primary.h.


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