Map the &ocean_vmix_nml buoyancy_coeffs string to a
BUOY_COEFFS_* tag; BUOY_COEFFS_INVALID for an unrecognised
string, which configure_ocean_vmix turns into a fail-loud abort
(never a silent fallback to the constants). The accepted set
must match the nml_enum allowed= list in register_ocean_vmix.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=*), | intent(in) | :: | name |
pure function parse_buoyancy_coeffs(name) result(tag) !! Map the `&ocean_vmix_nml buoyancy_coeffs` string to a !! `BUOY_COEFFS_*` tag; `BUOY_COEFFS_INVALID` for an unrecognised !! string, which `configure_ocean_vmix` turns into a fail-loud abort !! (never a silent fallback to the constants). The accepted set !! must match the `nml_enum allowed=` list in `register_ocean_vmix`. character(len=*), intent(in) :: name integer :: tag select case (trim(name)) case ("constant") tag = BUOY_COEFFS_CONSTANT case ("eos") tag = BUOY_COEFFS_EOS case default tag = BUOY_COEFFS_INVALID end select end function parse_buoyancy_coeffs