IAP GITLAB

Skip to content
Snippets Groups Projects
Commit 18d16d1c authored by Ralf Ulrich's avatar Ralf Ulrich
Browse files

Merge branch '408-rename-corsika-state' into 'master'

Resolve "Rename corsika::State"

Closes #408

See merge request !344
parents c24339ce 6c99483b
No related branches found
No related tags found
1 merge request!344Resolve "Rename corsika::State"
Pipeline #4073 passed
......@@ -36,7 +36,7 @@ namespace corsika {
static double Z_over_A() { return data_.Z_over_A(); }
static double getSternheimerDensity() { return data_.getSternheimerDensity(); }
static double getCorrectedDensity() { return data_.getCorrectedDensity(); }
static State getState() { return data_.getState(); }
static StateOfMatter getStateOfMatter() { return data_.getStateOfMatter(); }
static MediumType getType() { return data_.getType(); }
static std::string const getSymbol() { return data_.getSymbol(); }
......@@ -50,7 +50,7 @@ namespace corsika {
inline static const MediumData data_ { "hydrogen_gas", "hydrogen gas (H%2#)", 1.008,
3, 7, 0.99212,
8.3748e-05, 8.3755e-05, State::DiatomicGas,
8.3748e-05, 8.3755e-05, StateOfMatter::DiatomicGas,
MediumType::Element, "H", 19.2, 9.5835, 1.8639, 3.2718, 0.14092, 5.7273, 0.0 };
@endcode
......@@ -73,7 +73,7 @@ namespace corsika {
};
//! Physical state of medium
enum class State { Unknown, Solid, Liquid, Gas, DiatomicGas };
enum class StateOfMatter { Unknown, Solid, Liquid, Gas, DiatomicGas };
enum class Medium : int16_t;
......@@ -93,7 +93,7 @@ namespace corsika {
double Z_over_A_;
double sternheimer_density_;
double corrected_density_;
State state_;
StateOfMatter state_;
MediumType type_;
std::string symbol_;
double Ieff_;
......@@ -122,17 +122,17 @@ namespace corsika {
} /// Sternheimer density
double getCorrectedDensity() const {
return corrected_density_;
} /// corrected density
State getState() const { return state_; } /// state
MediumType getType() const { return type_; } /// type
std::string getSymbol() const { return symbol_; } /// symbol
double getIeff() const { return Ieff_; } /// Ieff
double getCbar() const { return Cbar_; } /// Cbar
double getX0() const { return x0_; } /// X0
double getX1() const { return x1_; } /// X1
double getAA() const { return aa_; } /// AA
double getSK() const { return sk_; } /// Sk
double getDlt0() const { return dlt0_; } /// Delta0
} /// corrected density
StateOfMatter getStateOfMatter() const { return state_; } /// state
MediumType getType() const { return type_; } /// type
std::string getSymbol() const { return symbol_; } /// symbol
double getIeff() const { return Ieff_; } /// Ieff
double getCbar() const { return Cbar_; } /// Cbar
double getX0() const { return x0_; } /// X0
double getX1() const { return x1_; } /// X1
double getAA() const { return aa_; } /// AA
double getSK() const { return sk_; } /// Sk
double getDlt0() const { return dlt0_; } /// Delta0
//! @}
};
......
......@@ -285,7 +285,7 @@ def gen_classes(media_db):
* - Sternheimer index: {stern_index}, label: {stern_label}, name: {name}, nice_name: {nice_name}, symbol: {symbol}
* - weight: {weight}, weight_significant_figure: {weight_significant_figure}, weight_error_last_digit: {weight_error_last_digit}
* - Z_over_A: {Z_over_A}, sternheimhers_density: {sternheimer_density}, corrected_density: {corrected_density},
* - State::{state}, MediumType::{type}, Ieff={Ieff}, Cbar={Cbar}, X0={x0}, x1={x1}, aa={aa}, sk={sk}, dlt0={dlt0}
* - StateOfMatter::{state}, MediumType::{type}, Ieff={Ieff}, Cbar={Cbar}, X0={x0}, x1={x1}, aa={aa}, sk={sk}, dlt0={dlt0}
**/
class {cname} {{
......@@ -301,7 +301,7 @@ def gen_classes(media_db):
static double Z_over_A() {{ return data_.Z_over_A(); }}
static double getSternheimerDensity() {{ return data_.getSternheimerDensity(); }}
static double getCorrectedDensity() {{ return data_.getCorrectedDensity(); }}
static State getState() {{ return data_.getState(); }}
static StateOfMatter getStateOfMatter() {{ return data_.getStateOfMatter(); }}
static MediumType getType() {{ return data_.getType(); }}
static std::string const getSymbol() {{ return data_.getSymbol(); }}
......@@ -318,7 +318,7 @@ def gen_classes(media_db):
inline static const MediumData data_ {{ "{name}", "{nice_name}", {weight},
{weight_significant_figure}, {weight_error_last_digit}, {Z_over_A},
{sternheimer_density}, {corrected_density}, State::{state},
{sternheimer_density}, {corrected_density}, StateOfMatter::{state},
MediumType::{type}, "{symbol}", {Ieff}, {Cbar}, {x0}, {x1}, {aa}, {sk}, {dlt0} }};
/** @endcond */
}};
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment