Geant4 11.4.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
GIDI::Sums::Sums Class Reference

#include <GIDI.hpp>

Inheritance diagram for GIDI::Sums::Sums:

Public Member Functions

 Sums ()
 ~Sums ()
SuitecrossSectionSums ()
Suite const & crossSectionSums () const
SuitemultiplicitySums ()
Suite const & multiplicitySums () const
void parse (Construction::Settings const &a_construction, HAPI::Node const &a_node, SetupInfo &a_setupInfo, PoPI::Database const &a_pops, PoPI::Database const &a_internalPoPs)
GUPI::AncestryfindInAncestry3 (std::string const &a_item)
GUPI::Ancestry const * findInAncestry3 (std::string const &a_item) const
void toXMLList (GUPI::WriteInfo &a_writeInfo, std::string const &a_indent="") const
Public Member Functions inherited from GUPI::Ancestry
 Ancestry (std::string const &a_moniker, std::string const &a_attribute="")
virtual ~Ancestry ()
Ancestryoperator= (Ancestry const &a_ancestry)
std::string const & moniker () const
void setMoniker (std::string const &a_moniker)
Ancestryancestor ()
Ancestry const * ancestor () const
void setAncestor (Ancestry *a_ancestor)
std::string attribute () const
Ancestryroot ()
Ancestry const * root () const
bool isChild (Ancestry *a_instance)
bool isParent (Ancestry *a_parent)
bool isRoot () const
AncestryfindInAncestry (std::string const &a_href)
Ancestry const * findInAncestry (std::string const &a_href) const
virtual LUPI_HOST void serialize (LUPI::DataBuffer &a_buffer, LUPI::DataBuffer::Mode a_mode)
virtual std::string xlinkItemKey () const
std::string toXLink () const
void printXML () const

Additional Inherited Members

Static Public Member Functions inherited from GUPI::Ancestry
static std::string buildXLinkItemKey (std::string const &a_name, std::string const &a_key)

Detailed Description

This class represents the GNDS <sums> node.

Definition at line 4497 of file GIDI.hpp.

Constructor & Destructor Documentation

◆ Sums()

GIDI::Sums::Sums::Sums ( )

Definition at line 25 of file GIDI_sums.cc.

25 :
26 GUPI::Ancestry( GIDI_sumsChars ),
27 m_crossSectionSums( GIDI_sumsCrossSectionsChars, GIDI_labelChars ),
28 m_multiplicitySums( GIDI_sumsMultiplicitiesChars, GIDI_labelChars ) {
29
30}
#define GIDI_sumsMultiplicitiesChars
Definition GIDI.hpp:206
#define GIDI_labelChars
Definition GIDI.hpp:438
#define GIDI_sumsChars
Definition GIDI.hpp:204
#define GIDI_sumsCrossSectionsChars
Definition GIDI.hpp:205

◆ ~Sums()

GIDI::Sums::Sums::~Sums ( )

Definition at line 35 of file GIDI_sums.cc.

35 {
36
37}

Member Function Documentation

◆ crossSectionSums() [1/2]

Suite & GIDI::Sums::Sums::crossSectionSums ( )
inline

Returns the value of the m_crossSectionSums member.

Definition at line 4507 of file GIDI.hpp.

◆ crossSectionSums() [2/2]

Suite const & GIDI::Sums::Sums::crossSectionSums ( ) const
inline

Returns the value of the m_crossSectionSums member.

Definition at line 4508 of file GIDI.hpp.

◆ findInAncestry3() [1/2]

GUPI::Ancestry * GIDI::Sums::Sums::findInAncestry3 ( std::string const & a_item)
virtual

Returns a pointer to the member whose moniker is a_item.

Parameters
a_item[in] The moniker of the member to return.
Returns
Returns the pointer to the member of nullptr if it does not exists.

Implements GUPI::Ancestry.

Definition at line 72 of file GIDI_sums.cc.

72 {
73
74 if( a_item == GIDI_crossSectionSumsChars ) return( &m_crossSectionSums );
75 if( a_item == GIDI_multiplicitySumsChars ) return( &m_multiplicitySums );
76
77 if( a_item == GIDI_sumsCrossSectionsChars ) return( &m_crossSectionSums ); // GNDS 1.10.
78 if( a_item == GIDI_sumsMultiplicitiesChars ) return( &m_multiplicitySums ); // GNDS 1.10.
79
80 return( nullptr );
81}
#define GIDI_multiplicitySumsChars
Definition GIDI.hpp:211
#define GIDI_crossSectionSumsChars
Definition GIDI.hpp:209

◆ findInAncestry3() [2/2]

GUPI::Ancestry const * GIDI::Sums::Sums::findInAncestry3 ( std::string const & a_item) const
virtual

Returns a pointer to the member whose moniker is a_item.

Parameters
a_item[in] The moniker of the member to return.
Returns
Returns the pointer to the member of nullptr if it does not exists.

Implements GUPI::Ancestry.

Definition at line 90 of file GIDI_sums.cc.

90 {
91
92 if( a_item == GIDI_crossSectionSumsChars ) return( &m_crossSectionSums );
93 if( a_item == GIDI_multiplicitySumsChars ) return( &m_multiplicitySums );
94
95 if( a_item == GIDI_sumsCrossSectionsChars ) return( &m_crossSectionSums ); // GNDS 1.10.
96 if( a_item == GIDI_sumsMultiplicitiesChars ) return( &m_multiplicitySums ); // GNDS 1.10.
97
98 return( nullptr );
99}

◆ multiplicitySums() [1/2]

Suite & GIDI::Sums::Sums::multiplicitySums ( )
inline

Returns the value of the m_multiplicitySums member.

Definition at line 4509 of file GIDI.hpp.

◆ multiplicitySums() [2/2]

Suite const & GIDI::Sums::Sums::multiplicitySums ( ) const
inline

Returns the value of the m_multiplicitySums member.

Definition at line 4510 of file GIDI.hpp.

◆ parse()

void GIDI::Sums::Sums::parse ( Construction::Settings const & a_construction,
HAPI::Node const & a_node,
SetupInfo & a_setupInfo,
PoPI::Database const & a_pops,
PoPI::Database const & a_internalPoPs )

The Sums method to parse its sub-nodes.

Parameters
a_construction[in] Used to pass user options to the constructor.
a_node[in] The HAPI::Node to be parsed.
a_setupInfo[in] Information create my the Protare constructor to help in parsing.
a_pops[in] A PoPI::Database instance used to get particle indices and possibly other particle information.
a_internalPoPs[in] The internal PoPI::Database instance used to get particle indices and possibly other particle information. This is the <PoPs> node under the <reactionSuite> node.

Definition at line 50 of file GIDI_sums.cc.

51 {
52
54 if( a_node.child( GIDI_crossSectionSumsChars ).empty( ) ) moniker = GIDI_sumsCrossSectionsChars;
55 m_crossSectionSums.parse( a_construction, a_node.child( moniker ), a_setupInfo, a_pops, a_internalPoPs, parseSumsCrossSectionsSuite, nullptr );
56
59 m_multiplicitySums.parse( a_construction, a_node.child( moniker ), a_setupInfo, a_pops, a_internalPoPs, parseSumsMultiplicitiesSuite, nullptr );
60
61 m_crossSectionSums.setAncestor( this );
62 m_multiplicitySums.setAncestor( this );
63}
std::string const & moniker() const
Definition GUPI.hpp:102
Form * parseSumsMultiplicitiesSuite(Construction::Settings const &a_construction, Suite *a_parent, HAPI::Node const &a_node, SetupInfo &a_setupInfo, PoPI::Database const &a_pops, PoPI::Database const &a_internalPoPs, std::string const &a_name, Styles::Suite const *a_styles)
Form * parseSumsCrossSectionsSuite(Construction::Settings const &a_construction, Suite *a_parent, HAPI::Node const &a_node, SetupInfo &a_setupInfo, PoPI::Database const &a_pops, PoPI::Database const &a_internalPoPs, std::string const &a_name, Styles::Suite const *a_styles)

◆ toXMLList()

void GIDI::Sums::Sums::toXMLList ( GUPI::WriteInfo & a_writeInfo,
std::string const & a_indent = "" ) const
virtual

Fills the argument a_writeInfo with the XML lines that represent this. Recursively enters each sub-node.

Parameters
a_writeInfo[in/out] Instance containing incremental indentation and other information and stores the appended lines.
a_indent[in] The amount to indent this node.

Reimplemented from GUPI::Ancestry.

Definition at line 108 of file GIDI_sums.cc.

108 {
109
110 std::string indent2 = a_writeInfo.incrementalIndent( a_indent );
111
112 a_writeInfo.addNodeStarter( a_indent, moniker( ), "" );
113 m_crossSectionSums.toXMLList( a_writeInfo, indent2 );
114 m_multiplicitySums.toXMLList( a_writeInfo, indent2 );
115 a_writeInfo.addNodeEnder( moniker( ) );
116}
void addNodeEnder(std::string const &a_moniker)
Definition GUPI.hpp:59
std::string incrementalIndent(std::string const &indent)
Definition GUPI.hpp:52
void addNodeStarter(std::string const &indent, std::string const &a_moniker, std::string const &a_attributes="")
Definition GUPI.hpp:55

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