Geant4-11
Public Member Functions | Protected Attributes | Private Attributes | Friends
G4tgrElementSimple Class Reference

#include <G4tgrElementSimple.hh>

Inheritance diagram for G4tgrElementSimple:
G4tgrElement

Public Member Functions

 G4tgrElementSimple ()
 
 G4tgrElementSimple (const std::vector< G4String > &wl)
 
G4double GetA () const
 
const G4StringGetName () const
 
const G4StringGetSymbol () const
 
const G4StringGetType () const
 
G4double GetZ () const
 
 ~G4tgrElementSimple ()
 

Protected Attributes

G4String theName
 
G4String theSymbol
 
G4String theType
 

Private Attributes

G4double theA = 0.0
 
G4double theZ = 0.0
 

Friends

std::ostream & operator<< (std::ostream &os, const G4tgrElementSimple &obj)
 

Detailed Description

Definition at line 42 of file G4tgrElementSimple.hh.

Constructor & Destructor Documentation

◆ G4tgrElementSimple() [1/2]

G4tgrElementSimple::G4tgrElementSimple ( )

Definition at line 38 of file G4tgrElementSimple.cc.

39{
40}

◆ ~G4tgrElementSimple()

G4tgrElementSimple::~G4tgrElementSimple ( )

Definition at line 43 of file G4tgrElementSimple.cc.

44{
45}

◆ G4tgrElementSimple() [2/2]

G4tgrElementSimple::G4tgrElementSimple ( const std::vector< G4String > &  wl)

Definition at line 48 of file G4tgrElementSimple.cc.

49{
50 //---------- Check for miminum number of words read
52 "G4tgrElementSimple::G4tgrElementSimple");
53
54 theType = "ElementSimple";
57 theZ = G4tgrUtils::GetInt(wl[3]);
58 theA = G4tgrUtils::GetDouble(wl[4], g / mole);
59
60#ifdef G4VERBOSE
62 {
63 G4cout << " Created " << *this << G4endl;
64 }
65#endif
66}
static constexpr double mole
Definition: G4SIunits.hh:279
static constexpr double g
Definition: G4SIunits.hh:168
#define G4endl
Definition: G4ios.hh:57
G4GLOB_DLL std::ostream G4cout
@ WLSIZE_EQ
Definition: G4tgrUtils.hh:47
G4String theName
Definition: G4tgrElement.hh:52
G4String theSymbol
Definition: G4tgrElement.hh:53
G4String theType
Definition: G4tgrElement.hh:54
static G4int GetVerboseLevel()
static G4String GetString(const G4String &str)
Definition: G4tgrUtils.cc:173
static void CheckWLsize(const std::vector< G4String > &wl, unsigned int nWCheck, WLSIZEtype st, const G4String &methodName)
Definition: G4tgrUtils.cc:490
static G4int GetInt(const G4String &str)
Definition: G4tgrUtils.cc:447
static G4double GetDouble(const G4String &str, G4double unitval=1.)
Definition: G4tgrUtils.cc:198

References G4tgrUtils::CheckWLsize(), g, G4cout, G4endl, G4tgrUtils::GetDouble(), G4tgrUtils::GetInt(), G4tgrUtils::GetString(), G4tgrMessenger::GetVerboseLevel(), mole, theA, G4tgrElement::theName, G4tgrElement::theSymbol, G4tgrElement::theType, theZ, and WLSIZE_EQ.

Member Function Documentation

◆ GetA()

G4double G4tgrElementSimple::GetA ( ) const
inline

Definition at line 54 of file G4tgrElementSimple.hh.

54{ return theA; }

References theA.

Referenced by G4tgbElement::BuildG4ElementSimple().

◆ GetName()

const G4String & G4tgrElement::GetName ( ) const
inlineinherited

◆ GetSymbol()

const G4String & G4tgrElement::GetSymbol ( ) const
inlineinherited

◆ GetType()

const G4String & G4tgrElement::GetType ( ) const
inlineinherited

Definition at line 48 of file G4tgrElement.hh.

48{ return theType; }

References G4tgrElement::theType.

Referenced by G4tgbElement::GetType().

◆ GetZ()

G4double G4tgrElementSimple::GetZ ( ) const
inline

Definition at line 53 of file G4tgrElementSimple.hh.

53{ return theZ; }

References theZ.

Referenced by G4tgbElement::BuildG4ElementSimple().

Friends And Related Function Documentation

◆ operator<<

std::ostream & operator<< ( std::ostream &  os,
const G4tgrElementSimple obj 
)
friend

Definition at line 69 of file G4tgrElementSimple.cc.

70{
71 os << "G4tgrElementSimple= " << obj.theName << " Z = " << obj.theZ
72 << " A= " << obj.theA << G4endl;
73
74 return os;
75}

Field Documentation

◆ theA

G4double G4tgrElementSimple::theA = 0.0
private

Definition at line 62 of file G4tgrElementSimple.hh.

Referenced by G4tgrElementSimple(), and GetA().

◆ theName

G4String G4tgrElement::theName
protectedinherited

◆ theSymbol

G4String G4tgrElement::theSymbol
protectedinherited

◆ theType

G4String G4tgrElement::theType
protectedinherited

◆ theZ

G4double G4tgrElementSimple::theZ = 0.0
private

Definition at line 61 of file G4tgrElementSimple.hh.

Referenced by G4tgrElementSimple(), and GetZ().


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