feat(cpp-object-oriented-modular-refactoring): step 19 - boundary-condition-policy
This commit is contained in:
@@ -7,6 +7,8 @@
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
#include "fesa/constraints/boundary_condition.h"
|
||||
#include "fesa/constraints/prescribed_displacement.h"
|
||||
#include "fesa/core/status.h"
|
||||
#include "fesa/loads/concentrated_nodal_load.h"
|
||||
#include "fesa/loads/load.h"
|
||||
@@ -58,8 +60,12 @@ class StepDefinition {
|
||||
/// @brief Returns the source step name.
|
||||
const std::string& Name() const noexcept;
|
||||
|
||||
/// @brief Returns current boundary records in declaration order.
|
||||
const std::vector<BoundaryCondition>& Boundaries() const noexcept;
|
||||
/// @brief Returns polymorphic boundaries in stable source/component order.
|
||||
const BoundaryConditionView& BoundaryConditions() const noexcept;
|
||||
|
||||
/// @brief Returns prescribed displacements in stable source/component order.
|
||||
const DomainCollectionView<PrescribedDisplacementBoundaryCondition>&
|
||||
PrescribedDisplacements() const noexcept;
|
||||
|
||||
/// @brief Returns polymorphic loads in stable source order.
|
||||
const LoadView& Loads() const noexcept;
|
||||
@@ -90,7 +96,10 @@ class StepDefinition {
|
||||
explicit StepDefinition(StaticStepDefinition definition);
|
||||
|
||||
std::string name_;
|
||||
std::vector<BoundaryCondition> boundaries_;
|
||||
std::vector<std::unique_ptr<BoundaryCondition>> boundary_conditions_;
|
||||
BoundaryConditionView boundary_conditions_view_;
|
||||
DomainCollectionView<PrescribedDisplacementBoundaryCondition>
|
||||
prescribed_displacements_view_;
|
||||
std::vector<std::unique_ptr<Load>> loads_;
|
||||
LoadView loads_view_;
|
||||
DomainCollectionView<ConcentratedNodalLoad> concentrated_loads_view_;
|
||||
|
||||
@@ -36,7 +36,7 @@ struct ShellNodeInitialFrame {
|
||||
};
|
||||
|
||||
/// @brief Stores one prescribed nodal degree-of-freedom range.
|
||||
struct BoundaryCondition {
|
||||
struct PrescribedDisplacementDefinition {
|
||||
std::string target;
|
||||
int first_dof;
|
||||
int last_dof;
|
||||
@@ -55,7 +55,7 @@ struct NodalLoad {
|
||||
/// @brief Stores the approved single linear-static step definition.
|
||||
struct StaticStepDefinition {
|
||||
std::string name;
|
||||
std::vector<BoundaryCondition> boundaries;
|
||||
std::vector<PrescribedDisplacementDefinition> boundaries;
|
||||
std::vector<NodalLoad> loads;
|
||||
double initial_increment;
|
||||
double time_period;
|
||||
|
||||
Reference in New Issue
Block a user