hstnmlinfonames.f90 File Reference

Go to the source code of this file.

Functions/Subroutines

character(string) function hstnmlinfonames (gthstnml)
 

Function/Subroutine Documentation

◆ hstnmlinfonames()

character(string) function hstnmlinfonames ( type(gthst_nmlinfo), intent(in)  gthstnml)

Definition at line 11 of file hstnmlinfonames.f90.

References dc_types::dp, dc_string::joinchar(), gtool_history_nmlinfo_internal::name_delimiter, dc_types::stdout, dc_types::string, and dc_types::token.

11  !
12  ! *gthstnml* が設定されている変数リストをカンマでつなげて
13  ! 返します.
14  !
15  ! なお, 与えられた *gthstnml* が HstNmlInfoCreate によって初期設定
16  ! されていない場合, 空文字が返ります.
17  !
18  ! List of variables registered in *gthstnml* is join with camma,
19  ! and returned.
20  !
21  ! If *gthstnml* is not initialized by "HstNmlInfoCreate" yet,
22  ! blank is returned.
23  !
28  use dc_types, only: dp, string, token, stdout
29  implicit none
30  character(STRING):: result
31  type(gthst_nmlinfo), intent(in):: gthstnml
32 
33  !-----------------------------------
34  ! 作業変数
35  ! Work variables
36  type(gthst_nmlinfo_entry), pointer:: hptr =>null()
37  logical:: first
38 !!$ character(*), parameter:: subname = 'HstNmlInfoNames'
39  continue
40 
41  result = ''
42  first = .true.
43 
44  !-----------------------------------------------------------------
45  ! 初期設定のチェック
46  ! Check initialization
47  !-----------------------------------------------------------------
48  if ( .not. gthstnml % initialized ) goto 999
49 
50  !-----------------------------------------------------------------
51  ! 情報の取り出し
52  ! Fetch information
53  !-----------------------------------------------------------------
54  hptr => gthstnml % gthstnml_list
55  do while ( associated( hptr % next ) )
56  call listnext( gthstnml_list = hptr ) ! (inout)
57  if ( first ) then
58  result = adjustl( hptr % name )
59  first = .false.
60  else
61  result = trim( result ) // name_delimiter // adjustl( hptr % name )
62  end if
63  end do
64 
65  !-----------------------------------------------------------------
66  ! 終了処理, 例外処理
67  ! Termination and Exception handling
68  !-----------------------------------------------------------------
69 999 continue
70  nullify( hptr )
integer, parameter, public token
単語やキーワードを保持する文字型変数の種別型パラメタ
Definition: dc_types.f90:109
character(1), parameter, public name_delimiter
character(string) function, public joinchar(carray, expr)
Definition: dc_string.f90:861
integer, parameter, public dp
倍精度実数型変数
Definition: dc_types.f90:83
integer, parameter, public stdout
標準出力の装置番号
Definition: dc_types.f90:98
文字型変数の操作.
Definition: dc_string.f90:24
種別型パラメタを提供します。
Definition: dc_types.f90:49
integer, parameter, public string
文字列を保持する 文字型変数の種別型パラメタ
Definition: dc_types.f90:118
Here is the call graph for this function: