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

#include <HAPI.hpp>

Public Member Functions

 Attribute ()
 Attribute (Node_internal *a_node, std::string const &a_name)
 ~Attribute ()=default
std::string const value () const
int as_int () const
long as_long () const
double as_double () const

Detailed Description

Definition at line 47 of file HAPI.hpp.

Constructor & Destructor Documentation

◆ Attribute() [1/2]

HAPI::Attribute::Attribute ( )
inline

Definition at line 55 of file HAPI.hpp.

55: m_node(nullptr), m_name() {}

◆ Attribute() [2/2]

HAPI::Attribute::Attribute ( Node_internal * a_node,
std::string const & a_name )
inline

Definition at line 57 of file HAPI.hpp.

57 :
58 m_node(a_node),
59 m_name(a_name)
60 {
61 }

◆ ~Attribute()

HAPI::Attribute::~Attribute ( )
default

Member Function Documentation

◆ as_double()

double HAPI::Attribute::as_double ( ) const
inline

Definition at line 140 of file HAPI.hpp.

140{ return( m_node->attribute_as_double(m_name.c_str()) ); }

◆ as_int()

int HAPI::Attribute::as_int ( ) const
inline

Definition at line 138 of file HAPI.hpp.

138{ return( m_node->attribute_as_int(m_name.c_str()) ); }

◆ as_long()

long HAPI::Attribute::as_long ( ) const
inline

Definition at line 139 of file HAPI.hpp.

139{ return( m_node->attribute_as_long(m_name.c_str()) ); }

◆ value()

std::string const HAPI::Attribute::value ( ) const
inline

Definition at line 137 of file HAPI.hpp.

137{ return( m_node->attribute( m_name.c_str()) ); }

Referenced by PoPI::Decay::Decay().


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