Flow123d
3.9.0-44fe12069
|
Helper class storing unit conversion coefficient and functionality for conversion of units. More...
#include <time_governor.hh>
Public Member Functions | |
TimeUnitConversion () | |
TimeUnitConversion (const Input::Record &input) | |
double | read_time (Input::Iterator< Input::Tuple > time_it, double default_time) const |
double | read_coef (Input::Iterator< Input::Record > unit_it) const |
double | get_coef () const |
std::string | get_unit_string () const |
Static Public Member Functions | |
static Input::Type::Default | get_input_default () |
Protected Member Functions | |
double | read_unit_coef_from_input (const Input::Record &input) const |
Reads the Unit record and computes the coef. More... | |
Protected Attributes | |
double | coef_ |
Conversion coefficient of all time values within the equation. More... | |
std::string | unit_string_ |
String representation of global unit of all time values within the equation. More... | |
Helper class storing unit conversion coefficient and functionality for conversion of units.
This class has created one instance for each TimeGovernor object. This object is shared with all TimeSteps.
Definition at line 58 of file time_governor.hh.
TimeUnitConversion::TimeUnitConversion | ( | ) |
Definition at line 144 of file time_governor.cc.
TimeUnitConversion::TimeUnitConversion | ( | const Input::Record & | input | ) |
Definition at line 147 of file time_governor.cc.
|
inline |
Return global time unit coefficient of equation stored in coeff_.
Definition at line 87 of file time_governor.hh.
|
inlinestatic |
|
inline |
Return string representation of global time unit.
Definition at line 94 of file time_governor.hh.
double TimeUnitConversion::read_coef | ( | Input::Iterator< Input::Record > | unit_it | ) | const |
Read and return time unit coefficient given in unit_it or global coefficient of equation stored in coeff_, if iterator is not defined.
Definition at line 189 of file time_governor.cc.
double TimeUnitConversion::read_time | ( | Input::Iterator< Input::Tuple > | time_it, |
double | default_time | ||
) | const |
Read and return time value multiplied by coefficient of given unit or global coefficient of equation stored in coeff_. If time Tuple is not defined (e. g. Tuple is optional key) return default_time value.
Definition at line 169 of file time_governor.cc.
|
protected |
Reads the Unit record and computes the coef.
Definition at line 153 of file time_governor.cc.
|
protected |
Conversion coefficient of all time values within the equation.
Definition at line 104 of file time_governor.hh.
|
protected |
String representation of global unit of all time values within the equation.
Definition at line 107 of file time_governor.hh.