mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 13:45:36 -04:00
retrireve filename and length_multiplier from XML file and call methods similar to filename case for XML constructor
This commit is contained in:
parent
045bc34ec4
commit
5161da8031
2 changed files with 9 additions and 1 deletions
|
|
@ -7,13 +7,13 @@
|
|||
#include <unordered_map>
|
||||
|
||||
#include "hdf5.h"
|
||||
#include "pugixml.hpp"
|
||||
#include "xtensor/xtensor.hpp"
|
||||
|
||||
#include "openmc/memory.h" // for unique_ptr
|
||||
#include "openmc/particle.h"
|
||||
#include "openmc/position.h"
|
||||
#include "openmc/vector.h"
|
||||
#include "openmc/xml_interface.h"
|
||||
|
||||
#ifdef DAGMC
|
||||
#include "moab/AdaptiveKDTree.hpp"
|
||||
|
|
|
|||
|
|
@ -2324,6 +2324,14 @@ const std::string LibMesh::mesh_lib_type = "libmesh";
|
|||
|
||||
LibMesh::LibMesh(pugi::xml_node node) : UnstructuredMesh(node)
|
||||
{
|
||||
std::string& filename = node.get_node_value(node, "filename");
|
||||
double length_multiplier = std::stod(node.get_node_value(node, "length_multiplier"));
|
||||
set_mesh_pointer_from_filename(filename);
|
||||
set_length_multiplier(length_multiplier);
|
||||
if (specified_length_multiplier_) {
|
||||
libMesh::MeshTools::Modification::scale(*m_, length_multiplier_);
|
||||
}
|
||||
m_->prepare_for_use();
|
||||
initialize();
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue