37 use json_utils,
only: json_get
38 use utils,
only: neko_type_error
46 character(len=25),
parameter :: KNOWN_TYPES(1) = [ character(len=25) :: &
55 module subroutine constraint_factory(object, json,
design, simulation)
56 class(constraint_t),
allocatable,
intent(inout) :: object
57 type(json_file),
intent(inout) :: json
58 class(design_t),
intent(in) :: design
59 type(simulation_t),
target,
optional,
intent(inout) :: simulation
60 character(len=:),
allocatable :: type
62 if (
allocated(object))
then
67 call json_get(json,
"type", type)
68 select case (trim(type))
72 call neko_type_error(
"Constraint",
type, KNOWN_TYPES)
75 call object%init(json,
design, simulation)
76 end subroutine constraint_factory
78end submodule constraint_factory_mod
Implements the constraint_t type.
Implements the volume_constraint_t type. Either .
A constraint on the volume of the design.