mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 22:26:08 -04:00
Adding signatures for reading information from an XML node where necessary.
This commit is contained in:
parent
7a9d8c95af
commit
040965245d
13 changed files with 127 additions and 22 deletions
|
|
@ -211,13 +211,11 @@ void get_run_parameters(pugi::xml_node node_base)
|
|||
}
|
||||
}
|
||||
|
||||
void read_settings_xml()
|
||||
{
|
||||
void read_settings_xml() {
|
||||
using namespace settings;
|
||||
using namespace pugi;
|
||||
|
||||
// Check if settings.xml exists
|
||||
std::string filename = path_input + "settings.xml";
|
||||
std::string filename = settings::path_input + "settings.xml";
|
||||
if (!file_exists(filename)) {
|
||||
if (run_mode != RunMode::PLOTTING) {
|
||||
fatal_error(
|
||||
|
|
@ -245,6 +243,14 @@ void read_settings_xml()
|
|||
// Get root element
|
||||
xml_node root = doc.document_element();
|
||||
|
||||
read_settings_xml(root);
|
||||
}
|
||||
|
||||
void read_settings_xml(pugi::xml_node root)
|
||||
{
|
||||
using namespace settings;
|
||||
using namespace pugi;
|
||||
|
||||
// Verbosity
|
||||
if (check_for_node(root, "verbosity")) {
|
||||
verbosity = std::stoi(get_node_value(root, "verbosity"));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue