CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Static Public Member Functions | Static Private Attributes
CurrentG4Track Class Reference

#include <CurrentG4Track.h>

Static Public Member Functions

static void setTrack (const G4Track *)
 
static const G4Track * track ()
 

Static Private Attributes

static thread_local const G4Track * m_track = 0
 

Detailed Description

This class is NOT intended for general use. It provides immediate access to the currently tracked G4Track for places that can't access this information easily, like StackingAction. If an acceptable geant4 mechanism is found for this, this class will be removed.

Definition at line 14 of file CurrentG4Track.h.

Member Function Documentation

void CurrentG4Track::setTrack ( const G4Track *  t)
static

Definition at line 5 of file CurrentG4Track.cc.

References m_track, and tree::t.

6 {
7  m_track = t;
8 }
tuple t
Definition: tree.py:139
static thread_local const G4Track * m_track
const G4Track * CurrentG4Track::track ( )
static

Definition at line 10 of file CurrentG4Track.cc.

References m_track.

Referenced by KillSecondariesStackingAction::ClassifyNewTrack().

11 {
12  return m_track;
13 }
static thread_local const G4Track * m_track

Member Data Documentation

thread_local const G4Track * CurrentG4Track::m_track = 0
staticprivate

Definition at line 20 of file CurrentG4Track.h.

Referenced by setTrack(), and track().