21 public:: listnext, listlast, listsearch
34 character(*),
parameter,
public::
version = &
36 &
'$Id: gtool_history_nmlinfo_internal.f90,v 1.1 2009-05-11 15:15:15 morikawa Exp $' 44 module procedure hstnmlinfolistnext
57 subroutine hstnmlinfolistnext( &
58 & gthstnml_list, err )
74 use dc_trace
, only: beginsub, endsub
80 logical,
intent(out),
optional:: err
99 character(STRING):: cause_c
100 character(*),
parameter:: subname =
'HstNmlInfoListNext' 102 call beginsub( subname )
110 if ( .not.
associated( gthstnml_list ) )
goto 999
116 gthstnml_list => gthstnml_list % next
123 call storeerror( stat, subname, err, cause_c )
124 call endsub( subname )
125 end subroutine hstnmlinfolistnext
128 & gthstnml_list, previous, err )
146 use dc_trace
, only: beginsub, endsub
154 logical,
intent(out),
optional:: err
173 character(STRING):: cause_c
174 character(*),
parameter:: subname =
'HstNmlInfoListLast' 176 call beginsub( subname )
180 if (
present( previous ) )
nullify( previous )
186 if ( .not.
associated( gthstnml_list ) )
goto 999
192 do while (
associated( gthstnml_list % next ) )
193 if (
present( previous ) ) previous => gthstnml_list
194 call listnext( gthstnml_list = gthstnml_list )
202 call storeerror( stat, subname, err, cause_c )
203 call endsub( subname )
207 & gthstnml_list, name, &
208 & previous, next, err )
239 use dc_trace
, only: beginsub, endsub
245 character(*),
intent(in):: name
255 logical,
intent(out),
optional:: err
274 character(STRING):: cause_c
275 character(*),
parameter:: subname =
'HstNmlInfoListSearch' 277 call beginsub( subname )
285 if ( .not.
associated( gthstnml_list ) )
goto 999
291 if (
present( previous ) )
nullify( previous )
292 if (
present( next ) )
nullify( next )
293 if ( trim( adjustl( gthstnml_list % name ) ) == trim( adjustl( name ) ) )
then 294 if (
present( next ) )
then 295 next => gthstnml_list % next
300 do while (
associated( gthstnml_list ) )
301 if (
present( previous ) ) previous => gthstnml_list
302 call listnext( gthstnml_list = gthstnml_list )
303 if ( .not.
associated( gthstnml_list ) )
goto 999
304 if ( trim( adjustl( gthstnml_list % name ) ) == trim( adjustl( name ) ) )
then 305 if (
present( next ) )
then 306 next => gthstnml_list % next
317 call storeerror( stat, subname, err, cause_c )
318 call endsub( subname )
subroutine hstnmlinfolistsearch(gthstnml_list, name, previous, next, err)
integer, parameter, public token
Character length for word, token.
type(hash), save, public opened_files
subroutine hstnmlinfolistlast(gthstnml_list, previous, err)
character(1), parameter, public name_delimiter
subroutine, public storeerror(number, where, err, cause_c, cause_i)
integer, parameter, public dc_noerr
character(*), parameter, public version
Provides kind type parameter values.
integer, parameter, public string
Character length for string.