libsim  Versione 7.2.6

◆ arrayof_gridinfo_remove()

subroutine arrayof_gridinfo_remove ( type(arrayof_gridinfo this,
integer, intent(in), optional  nelem,
integer, intent(in), optional  pos,
logical, intent(in), optional  nodestroy 
)

Method for removing elements of the array at a desired position.

If necessary, the array is reallocated to reduce space.

Parametri
thisarray object in which an element has to be removed
[in]nelemnumber of elements to remove, if not provided, a single element is removed
[in]posposition of the element to be removed, if it is out of range, it is clipped, if it is not provided, objects are removed at the end
[in]posif provided and .TRUE. , the destructor possibily defined for the TYPE(gridinfo_def) is not called for every deleted object, may be useful if the objects to be deleted have been copied to another instance of arrayof_gridinfo and continue their life there

Definizione alla linea 521 del file gridinfo_class.F90.

526  CALL l4f_category_log(category,l4f_error, &
527  "gridinfo object of size "//t2c(this%arraysize))
528  CALL l4f_category_log(category,l4f_error, &
529  "no valid grid id found when exporting to file "//trim(filename))
530  CALL raise_error()
531 ENDIF
532 
533 !chiudo il logger
534 CALL l4f_category_delete(category)
535 
536 END SUBROUTINE gridinfo_export_to_file
537 
538 
547 FUNCTION gridinfo_decode_data(this) RESULT(field)
548 TYPE(gridinfo_def),INTENT(in) :: this
549 REAL :: field(this%griddim%dim%nx, this%griddim%dim%ny) ! array of decoded values
550 
551 CALL grid_id_decode_data(this%gaid, field)
552 
553 END FUNCTION gridinfo_decode_data
554 
555 
563 SUBROUTINE gridinfo_encode_data(this, field)
564 TYPE(gridinfo_def),INTENT(inout) :: this
565 REAL,intent(in) :: field(:,:)
566 
567 IF (SIZE(field,1) /= this%griddim%dim%nx &
568  .OR. SIZE(field,2) /= this%griddim%dim%ny) THEN
569  CALL l4f_category_log(this%category,l4f_error, &
570  'gridinfo_encode: field and gridinfo object non conformal, field: ' &
571  //trim(to_char(SIZE(field,1)))//'X'//trim(to_char(SIZE(field,2)))//', nx,ny:' &
572  //trim(to_char(this%griddim%dim%nx))//'X'//trim(to_char(this%griddim%dim%ny)))
573  CALL raise_error()
574  RETURN
575 ENDIF
576 
577 CALL grid_id_encode_data(this%gaid, field)

Generated with Doxygen.