diff --git a/ProcessLib/LIE/SmallDeformation/CreateSmallDeformationProcess.cpp b/ProcessLib/LIE/SmallDeformation/CreateSmallDeformationProcess.cpp index 9d78afae37cb17ed298fa0d39c666a2192e709cd..6b80d734f3c66340c5773b6f1a493cc0768884cc 100644 --- a/ProcessLib/LIE/SmallDeformation/CreateSmallDeformationProcess.cpp +++ b/ProcessLib/LIE/SmallDeformation/CreateSmallDeformationProcess.cpp @@ -181,10 +181,10 @@ std::unique_ptr<Process> createSmallDeformationProcess( config.getConfigParameter<double>( "reference_temperature", std::numeric_limits<double>::quiet_NaN()); - SmallDeformationProcessData<DisplacementDim> process_data( + SmallDeformationProcessData<DisplacementDim> process_data{ materialIDs(mesh), std::move(solid_constitutive_relations), std::move(fracture_model), std::move(fracture_properties), - reference_temperature); + reference_temperature}; SecondaryVariableCollection secondary_variables; diff --git a/ProcessLib/LIE/SmallDeformation/SmallDeformationProcessData.h b/ProcessLib/LIE/SmallDeformation/SmallDeformationProcessData.h index 431265807da5fc6da07f646a58f36d343251bdad..aee0519a68707b540ac6feabfc7c1dde9da6b409 100644 --- a/ProcessLib/LIE/SmallDeformation/SmallDeformationProcessData.h +++ b/ProcessLib/LIE/SmallDeformation/SmallDeformationProcessData.h @@ -32,36 +32,6 @@ namespace SmallDeformation template <int DisplacementDim> struct SmallDeformationProcessData { - SmallDeformationProcessData( - MeshLib::PropertyVector<int> const* const material_ids_, - std::map<int, - std::unique_ptr< - MaterialLib::Solids::MechanicsBase<DisplacementDim>>>&& - solid_materials_, - std::unique_ptr< - MaterialLib::Fracture::FractureModelBase<DisplacementDim>>&& - fracture_model, - std::vector<FractureProperty>&& fracture_properties_, - double const reference_temperature) - : material_ids(material_ids_), - solid_materials{std::move(solid_materials_)}, - fracture_model{std::move(fracture_model)}, - fracture_properties(std::move(fracture_properties_)), - reference_temperature(reference_temperature) - { - } - - SmallDeformationProcessData(SmallDeformationProcessData&& other) = default; - - //! Copies are forbidden. - SmallDeformationProcessData(SmallDeformationProcessData const&) = delete; - - //! Assignments are not needed. - void operator=(SmallDeformationProcessData const&) = delete; - - //! Assignments are not needed. - void operator=(SmallDeformationProcessData&&) = delete; - MeshLib::PropertyVector<int> const* const material_ids; /// The constitutive relation for the mechanical part. @@ -73,14 +43,17 @@ struct SmallDeformationProcessData std::unique_ptr<MaterialLib::Fracture::FractureModelBase<DisplacementDim>> fracture_model; std::vector<FractureProperty> fracture_properties; - std::vector<JunctionProperty> junction_properties; + + double const reference_temperature; + + std::vector<JunctionProperty> junction_properties = {}; MeshLib::PropertyVector<int> const* mesh_prop_materialIDs = nullptr; - std::vector<int> map_materialID_to_fractureID; + std::vector<int> map_materialID_to_fractureID = {}; // a table of connected fracture IDs for each element - std::vector<std::vector<int>> vec_ele_connected_fractureIDs; - std::vector<std::vector<int>> vec_ele_connected_junctionIDs; + std::vector<std::vector<int>> vec_ele_connected_fractureIDs = {}; + std::vector<std::vector<int>> vec_ele_connected_junctionIDs = {}; // mesh properties to output element's stress. MeshLib::PropertyVector<double>* element_stresses = nullptr; @@ -89,8 +62,6 @@ struct SmallDeformationProcessData // mesh property for fracture aperture MeshLib::PropertyVector<double>* mesh_prop_b = nullptr; - - double const reference_temperature; }; } // namespace SmallDeformation