Decide if all/some of the normalisations have been set
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(norms_type), | intent(inout) | :: | self |
subroutine norms_set_logicals(self)
implicit none
class(norms_type), intent(in out) :: self
integer :: i
logical :: some_set, all_set
!Init internals
some_set=.false.
all_set=.true.
!Loop over parameters and set them to def_val
do i=1,len(self%names)
all_set=all_set.and.self%check_if_set(self%names(i))
some_set=some_set.or.self%check_if_set(self%names(i))
enddo
!Update object parameters
self%some_norms_set=some_set
self%all_norms_set=all_set
end subroutine norms_set_logicals