|
◆ vol7d_convr()
subroutine vol7d_class::vol7d_convr |
( |
type(vol7d), intent(in) |
this, |
|
|
type(vol7d), intent(inout) |
that, |
|
|
logical, intent(in), optional |
anaconv |
|
) |
| |
Metodo per convertire i volumi di dati di un oggetto vol7d in dati reali dove possibile.
L'oggetto convertito è una copia completa dell'originale che può essere quindi distrutto dopo la chiamata. Per i dati di anagrafica, al momento sono convertiti solo i dati CHARACTER se è passato anaconv=.TRUE. Gli attributi non sono toccati.
- Parametri
-
[in] | this | oggetto origine |
[in,out] | that | oggetto convertito |
[in] | anaconv | converti anche anagrafica |
Definizione alla linea 2281 del file vol7d_class.F90.
2283 IF ( ASSOCIATED(v7d_tmp%dativar%c)) THEN 2285 ALLOCATE(v7d_tmp%voldatir( SIZE(v7d_tmp%voldatic, 1), SIZE(v7d_tmp%voldatic, 2), & 2286 SIZE(v7d_tmp%voldatic, 3), SIZE(v7d_tmp%voldatic, 4), SIZE(v7d_tmp%voldatic, 5), & 2287 SIZE(v7d_tmp%voldatic, 6))) 2288 DO i = 1, SIZE(v7d_tmp%dativar%c) 2289 v7d_tmp%voldatir(:,:,:,:,i,:) = & 2290 realdat(v7d_tmp%voldatic(:,:,:,:,i,:), v7d_tmp%dativar%c(i)) 2292 DEALLOCATE(v7d_tmp%voldatic) 2294 v7d_tmp%dativar%r => v7d_tmp%dativar%c 2295 NULLIFY(v7d_tmp%dativar%c) 2299 CALL vol7d_merge(that, v7d_tmp) 2301 CALL delete(v7d_tmp) 2304 END SUBROUTINE vol7d_convr 2310 SUBROUTINE vol7d_diff_only (this, that, data_only,ana) 2311 TYPE(vol7d), INTENT(IN) :: this 2312 TYPE(vol7d), INTENT(OUT) :: that 2313 logical , optional, intent(in) :: data_only 2314 logical , optional, intent(in) :: ana 2315 logical :: ldata_only,lana 2317 IF ( PRESENT(data_only)) THEN 2318 ldata_only = data_only 2320 ldata_only = .false. 2323 IF ( PRESENT(ana)) THEN 2330 #undef VOL7D_POLY_ARRAY 2331 #define VOL7D_POLY_ARRAY voldati 2332 #include "vol7d_class_diff.F90" 2333 #undef VOL7D_POLY_ARRAY 2334 #define VOL7D_POLY_ARRAY voldatiattr 2335 #include "vol7d_class_diff.F90" 2336 #undef VOL7D_POLY_ARRAY 2338 if ( .not. ldata_only) then 2340 #define VOL7D_POLY_ARRAY volana 2341 #include "vol7d_class_diff.F90" 2342 #undef VOL7D_POLY_ARRAY 2343 #define VOL7D_POLY_ARRAY volanaattr 2344 #include "vol7d_class_diff.F90" 2345 #undef VOL7D_POLY_ARRAY 2348 where ( this%ana == that%ana ) 2349 that%ana = vol7d_ana_miss 2357 END SUBROUTINE vol7d_diff_only 2363 #undef VOL7D_POLY_TYPE 2364 #undef VOL7D_POLY_TYPES 2365 #define VOL7D_POLY_TYPE REAL 2366 #define VOL7D_POLY_TYPES r 2367 #include "vol7d_class_type_templ.F90" 2368 #undef VOL7D_POLY_TYPE 2369 #undef VOL7D_POLY_TYPES 2370 #define VOL7D_POLY_TYPE DOUBLE PRECISION 2371 #define VOL7D_POLY_TYPES d 2372 #include "vol7d_class_type_templ.F90" 2373 #undef VOL7D_POLY_TYPE 2374 #undef VOL7D_POLY_TYPES 2375 #define VOL7D_POLY_TYPE INTEGER 2376 #define VOL7D_POLY_TYPES i 2377 #include "vol7d_class_type_templ.F90" 2378 #undef VOL7D_POLY_TYPE 2379 #undef VOL7D_POLY_TYPES 2380 #define VOL7D_POLY_TYPE INTEGER(kind=int_b) 2381 #define VOL7D_POLY_TYPES b 2382 #include "vol7d_class_type_templ.F90" 2383 #undef VOL7D_POLY_TYPE 2384 #undef VOL7D_POLY_TYPES 2385 #define VOL7D_POLY_TYPE CHARACTER(len=vol7d_cdatalen) 2386 #define VOL7D_POLY_TYPES c 2387 #include "vol7d_class_type_templ.F90" 2392 #undef VOL7D_NO_ZERO_ALLOC 2393 #undef VOL7D_POLY_TYPE 2394 #define VOL7D_POLY_TYPE datetime 2395 #include "vol7d_class_desc_templ.F90" 2396 #undef VOL7D_POLY_TYPE 2397 #define VOL7D_POLY_TYPE vol7d_timerange 2398 #include "vol7d_class_desc_templ.F90" 2399 #undef VOL7D_POLY_TYPE 2400 #define VOL7D_POLY_TYPE vol7d_level 2401 #include "vol7d_class_desc_templ.F90" 2403 #undef VOL7D_POLY_TYPE 2404 #define VOL7D_POLY_TYPE vol7d_network 2405 #include "vol7d_class_desc_templ.F90" 2406 #undef VOL7D_POLY_TYPE 2407 #define VOL7D_POLY_TYPE vol7d_ana 2408 #include "vol7d_class_desc_templ.F90" 2409 #define VOL7D_NO_ZERO_ALLOC 2410 #undef VOL7D_POLY_TYPE 2411 #define VOL7D_POLY_TYPE vol7d_var 2412 #include "vol7d_class_desc_templ.F90" 2423 subroutine vol7d_write_on_file (this,unit,description,filename,filename_auto) 2425 TYPE(vol7d), INTENT(IN) :: this 2426 integer, optional, intent(inout) :: unit 2427 character(len=*), intent(in), optional :: filename 2428 character(len=*), intent(out), optional :: filename_auto 2429 character(len=*), INTENT(IN), optional :: description 2432 character(len=254) :: ldescription,arg,lfilename 2433 integer :: nana, ntime, ntimerange, nlevel, nnetwork, & 2434 ndativarr, ndativari, ndativarb, ndativard, ndativarc,& 2435 ndatiattrr, ndatiattri, ndatiattrb, ndatiattrd, ndatiattrc,& 2436 ndativarattrr, ndativarattri, ndativarattrb, ndativarattrd, ndativarattrc,& 2437 nanavarr, nanavari, nanavarb, nanavard, nanavarc,& 2438 nanaattrr, nanaattri, nanaattrb, nanaattrd, nanaattrc,& 2439 nanavarattrr, nanavarattri, nanavarattrb, nanavarattrd, nanavarattrc 2441 integer :: tarray(8) 2442 logical :: opened,exist 2482 call date_and_time(values=tarray) 2485 if ( present(description)) then 2486 ldescription=description 2488 ldescription= "Vol7d generated by: "//trim(arg) 2491 if (.not. present(unit)) then
|