Geant4-11
Public Member Functions | Protected Attributes
G4VUserTrackInformation Class Reference

#include <G4VUserTrackInformation.hh>

Inheritance diagram for G4VUserTrackInformation:
G4IT G4ScintillationTrackInformation G4Molecule

Public Member Functions

 G4VUserTrackInformation ()
 
 G4VUserTrackInformation (const G4String &infoType)
 
 G4VUserTrackInformation (const G4VUserTrackInformation &)
 
const G4StringGetType () const
 
G4VUserTrackInformationoperator= (const G4VUserTrackInformation &)
 
virtual void Print () const
 
virtual ~G4VUserTrackInformation ()
 

Protected Attributes

G4StringpType = nullptr
 

Detailed Description

Definition at line 54 of file G4VUserTrackInformation.hh.

Constructor & Destructor Documentation

◆ G4VUserTrackInformation() [1/3]

G4VUserTrackInformation::G4VUserTrackInformation ( )

Definition at line 34 of file G4VUserTrackInformation.cc.

35{}

◆ G4VUserTrackInformation() [2/3]

G4VUserTrackInformation::G4VUserTrackInformation ( const G4String infoType)

Definition at line 38 of file G4VUserTrackInformation.cc.

39{
40 pType = new G4String(infoType);
41}

References pType.

◆ G4VUserTrackInformation() [3/3]

G4VUserTrackInformation::G4VUserTrackInformation ( const G4VUserTrackInformation right)

Definition at line 51 of file G4VUserTrackInformation.cc.

53{
54 if(right.pType != nullptr)
55 pType = new G4String(*(right.pType));
56}

References pType.

◆ ~G4VUserTrackInformation()

G4VUserTrackInformation::~G4VUserTrackInformation ( )
virtual

Definition at line 44 of file G4VUserTrackInformation.cc.

45{
46 if(pType != nullptr)
47 delete pType;
48}

References pType.

Member Function Documentation

◆ GetType()

const G4String & G4VUserTrackInformation::GetType ( ) const

Definition at line 75 of file G4VUserTrackInformation.cc.

76{
77 static const G4String NOTYPE = "NONE";
78 if(pType != nullptr)
79 return *pType;
80 else
81 return NOTYPE;
82}

References pType.

Referenced by G4ScintillationTrackInformation::IsScintillationTrackInformation().

◆ operator=()

G4VUserTrackInformation & G4VUserTrackInformation::operator= ( const G4VUserTrackInformation right)

Definition at line 60 of file G4VUserTrackInformation.cc.

61{
62 if(this != &right)
63 {
64 if(pType != nullptr)
65 delete pType;
66 if(right.pType)
67 pType = new G4String(*(right.pType));
68 else
69 pType = nullptr;
70 }
71 return *this;
72}

References pType.

Referenced by G4ScintillationTrackInformation::operator=().

◆ Print()

virtual void G4VUserTrackInformation::Print ( ) const
inlinevirtual

Reimplemented in G4IT, and G4ScintillationTrackInformation.

Definition at line 68 of file G4VUserTrackInformation.hh.

68{};

Field Documentation

◆ pType

G4String* G4VUserTrackInformation::pType = nullptr
protected

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