46 logical,
intent(out),
optional:: err
64 character(STRING):: opname, opfile
70 character(STRING):: fullfilename
74 character(STRING):: cause_c
75 character(*),
parameter:: subname =
'HstNmlInfoEndDefine' 85 if ( .not. gthstnml % initialized )
then 87 cause_c =
'GTHST_NMLINFO' 91 if ( .not. gthstnml % define_mode )
then 101 hptr => gthstnml % gthstnml_list
102 if ( .not.
associated( hptr % history ) )
then 103 allocate( hptr % history )
105 wholeloop :
do while (
associated( hptr % next ) )
106 call listnext( gthstnml_list = hptr )
107 if ( trim(hptr % name) ==
'' .or. trim(hptr % file) ==
'' ) &
110 fullfilename = trim( hptr % fileprefix ) // hptr % file
120 & opname, opfile, end )
121 if ( end )
exit searchloop
122 if ( trim(opfile) /= trim(fullfilename) ) cycle searchloop
123 hptr_prev => gthstnml % gthstnml_list
127 if ( .not.
associated( hptr_prev ) ) cycle searchloop
128 if ( trim(hptr % name) == trim(hptr_prev % name) ) cycle searchloop
133 if ( hptr % interval_value /= hptr_prev % interval_value )
then 135 &
'@interval_value=%r (var=%a) and @interval_value=%r (var=%a) are applied to a file "%a"', &
136 & r = (/hptr % interval_value, hptr_prev % interval_value/), &
137 & ca =
stoa(hptr % name, hptr_prev % name, fullfilename) )
139 cause_c = fullfilename
141 elseif ( hptr % interval_unit /= hptr_prev % interval_unit )
then 143 &
'@interval_unit=%a (var=%a) and @interval_unit=%a (var=%a) are applied to a file "%a"', &
144 & ca =
stoa(hptr % interval_unit, hptr % name, &
145 & hptr_prev % interval_unit, hptr_prev % name, &
148 cause_c = fullfilename
155 if ( hptr % origin_value /= hptr_prev % origin_value )
then 157 &
'@origin_value=%r (var=%a) and @origin_value=%r (var=%a) are applied to a file "%a"', &
158 & r = (/hptr % origin_value, hptr_prev % origin_value/), &
159 & ca =
stoa(hptr % name, hptr_prev % name, fullfilename) )
161 cause_c = fullfilename
163 elseif ( hptr % origin_unit /= hptr_prev % origin_unit )
then 165 &
'@origin_unit=%a (var=%a) and @origin_unit=%a (var=%a) are applied to a file "%a"', &
166 & ca =
stoa(hptr % origin_unit, hptr % name, &
167 & hptr_prev % origin_unit, hptr_prev % name, &
170 cause_c = fullfilename
177 if ( hptr % terminus_value /= hptr_prev % terminus_value )
then 179 &
'@terminus_value=%r (var=%a) and @terminus_value=%r (var=%a) are applied to a file "%a"', &
180 & r = (/hptr % terminus_value, hptr_prev % terminus_value/), &
181 & ca =
stoa(hptr % name, hptr_prev % name, fullfilename) )
183 cause_c = fullfilename
185 elseif ( hptr % terminus_unit /= hptr_prev % terminus_unit )
then 187 &
'@terminus_unit=%a (var=%a) and @terminus_unit=%a (var=%a) are applied to a file "%a"', &
188 & ca =
stoa(hptr % terminus_unit, hptr % name, &
189 & hptr_prev % terminus_unit, hptr_prev % name, &
192 cause_c = fullfilename
199 if ( ( hptr % newfile_intvalue > 0.0 ) &
200 & .or. ( hptr_prev % newfile_intvalue > 0.0 ) )
then 202 &
'when @newfile_intvalue=%d (var=%a) > 0 or' // &
203 &
' @newfile_intvalue=%d (var=%a) > 0, multiple variables can not be output to one file "%a"', &
204 & i = (/hptr % newfile_intvalue, hptr_prev % newfile_intvalue/), &
205 & ca =
stoa(hptr % name, hptr_prev % name, fullfilename) )
207 cause_c = fullfilename
214 if ( hptr % newfile_intvalue /= hptr_prev % newfile_intvalue )
then 216 &
'@newfile_intvalue=%d (var=%a) and @newfile_intvalue=%d (var=%a) are applied to a file "%a"', &
217 & i = (/hptr % newfile_intvalue, hptr_prev % newfile_intvalue/), &
218 & ca =
stoa(hptr % name, hptr_prev % name, fullfilename) )
220 cause_c = fullfilename
222 elseif ( hptr % newfile_intunit /= hptr_prev % newfile_intunit )
then 224 &
'@newfile_intunit=%a (var=%a) and @newfile_intunit=%a (var=%a) are applied to a file "%a"', &
225 & ca =
stoa(hptr % newfile_intunit, hptr % name, &
226 & hptr_prev % newfile_intunit, hptr_prev % name, &
229 cause_c = fullfilename
237 if ( any( hptr % slice_start /= hptr_prev % slice_start ) )
then 239 &
'@slice_start=%*d (var=%a) and @slice_start=%*d (var=%a) are applied to a file "%a"', &
240 & i = (/hptr % slice_start(1:10), hptr_prev % slice_start(1:10)/), &
242 & ca =
stoa(hptr % name, hptr_prev % name, fullfilename) )
244 cause_c = fullfilename
246 elseif ( any( hptr % slice_end /= hptr_prev % slice_end ) )
then 248 &
'@slice_end=%*d (var=%a) and @slice_end=%*d (var=%a) are applied to a file "%a"', &
249 & i = (/hptr % slice_end(1:10), hptr_prev % slice_end(1:10)/), &
251 & ca =
stoa(hptr % name, hptr_prev % name, fullfilename) )
253 cause_c = fullfilename
255 elseif ( any( hptr % slice_stride /= hptr_prev % slice_stride ) )
then 257 &
'@slice_stride=%*d (var=%a) and @slice_stride=%*d (var=%a) are applied to a file "%a"', &
258 & i = (/hptr % slice_stride(1:10), hptr_prev % slice_stride(1:10)/), &
260 & ca =
stoa(hptr % name, hptr_prev % name, fullfilename) )
262 cause_c = fullfilename
270 hptr % history => hptr_prev % history
278 if ( .not.
associated( hptr % history ) )
then 279 allocate( hptr % history )
280 hptr % history % initialized = .false.
288 & hptr % name, fullfilename )
299 gthstnml % define_mode = .false.
301 call storeerror( stat, subname, err, cause_c )
integer, parameter, public hst_enotindefine
integer, parameter, public dc_enotinit
integer, parameter, public token
単語やキーワードを保持する文字型変数の種別型パラメタ
type(hash), save, public opened_files
integer, parameter, public hst_eintfile
subroutine, public storeerror(number, where, err, cause_c, cause_i)
integer, parameter, public dc_noerr
subroutine hstnmlinfoenddefine(gthstnml, err)
integer, parameter, public hst_ebadterminus
character(string) function, public joinchar(carray, expr)
integer, parameter, public hst_ebadslice
integer, parameter, public hst_ebadnewfileint
integer, parameter, public dp
倍精度実数型変数
subroutine, public beginsub(name, fmt, i, r, d, L, n, c1, c2, c3, ca, version)
integer, parameter, public stdout
標準出力の装置番号
subroutine, public endsub(name, fmt, i, r, d, L, n, c1, c2, c3, ca)
integer, parameter, public hst_ebadorigin
integer, parameter, public string
文字列を保持する 文字型変数の種別型パラメタ