make_GathervSpec Function

public function make_GathervSpec(rc) result(spec)

Arguments

Type IntentOptional Attributes Name
integer, intent(out), optional :: rc

Return Value type(GathervSpec)


Calls

proc~~make_gathervspec~~CallsGraph proc~make_gathervspec make_GathervSpec add_argument add_argument proc~make_gathervspec->add_argument argparser argparser proc~make_gathervspec->argparser at at proc~make_gathervspec->at cast cast proc~make_gathervspec->cast interface~mapl_assert MAPL_Assert proc~make_gathervspec->interface~mapl_assert parse_args parse_args proc~make_gathervspec->parse_args proc~mapl_return MAPL_Return proc~make_gathervspec->proc~mapl_return proc~mapl_verify MAPL_Verify proc~make_gathervspec->proc~mapl_verify proc~mapl_return->at insert insert proc~mapl_return->insert proc~mapl_throw_exception MAPL_throw_exception proc~mapl_return->proc~mapl_throw_exception proc~mapl_verify->proc~mapl_throw_exception

Called by

proc~~make_gathervspec~~CalledByGraph proc~make_gathervspec make_GathervSpec program~main~14 main program~main~14->proc~make_gathervspec

Source Code

   function make_GathervSpec(rc) result(spec)
      type(GathervSpec) :: spec
      integer, optional, intent(out) :: rc

      integer :: status
      type(ArgParser) :: parser
      type(StringUnlimitedMap) :: options
      class(*), pointer :: option

      parser = ArgParser()
      call add_cli_options(parser)
      options = parser%parse_args()
      
      option => options%at('nx')
      _ASSERT(associated(option), 'nx not found')
      call cast(option, spec%nx, _RC)

      option => options%at('n_levs')
      _ASSERT(associated(option), 'n_levs not found')
      call cast(option, spec%n_levs, _RC)


      option => options%at('n_writers')
      _ASSERT(associated(option), 'n_writers not found')
      call cast(option, spec%n_writers, _RC)


      option => options%at('n_tries')
      _ASSERT(associated(option), 'n_tries not found')
      call cast(option, spec%n_tries, _RC)
      
      _RETURN(_SUCCESS)
   end function make_GathervSpec