has_section Function

private elemental function has_section(self, section_name) result(pres)

Inquire the presence of (at least one) section with the name passed.

Arguments

TypeIntentOptionalAttributesName
class(file_ini), intent(in) :: self

File data.

character, intent(in) :: section_name

Section name.

Return Value logical

Inquiring flag.


Contents

Source Code


Source Code

  elemental function has_section(self, section_name) result(pres)
  !< Inquire the presence of (at least one) section with the name passed.
  class(file_ini), intent(in) :: self         !< File data.
  character(*),    intent(in) :: section_name !< Section name.
  logical                     :: pres         !< Inquiring flag.

  pres = (self%index(section_name=section_name)>0)
  endfunction has_section