|
|
◆ 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
-
| this | array object in which an element has to be removed |
| [in] | nelem | number of elements to remove, if not provided, a single element is removed |
| [in] | pos | position 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] | pos | if 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 526 del file gridinfo_class.F90.
528 CALL l4f_category_log(category,l4f_error, & 529 "gridinfo object of size "//t2c(this%arraysize)) 530 CALL l4f_category_log(category,l4f_error, & 531 "no valid grid id found when exporting to file "//trim(filename)) 536 CALL l4f_category_delete(category) 538 END SUBROUTINE gridinfo_export_to_file 549 FUNCTION gridinfo_decode_data(this) RESULT(field) 550 TYPE(gridinfo_def), INTENT(in) :: this 551 REAL :: field(this%griddim%dim%nx, this%griddim%dim%ny) 553 CALL grid_id_decode_data(this%gaid, field) 555 END FUNCTION gridinfo_decode_data 565 SUBROUTINE gridinfo_encode_data(this, field) 566 TYPE(gridinfo_def), INTENT(inout) :: this 567 REAL, intent(in) :: field(:,:) 569 IF ( SIZE(field,1) /= this%griddim%dim%nx & 570 .OR. SIZE(field,2) /= this%griddim%dim%ny) THEN 571 CALL l4f_category_log(this%category,l4f_error, & 572 'gridinfo_encode: field and gridinfo object non conformal, field: ' & 573 //trim(to_char( SIZE(field,1)))// 'X'//trim(to_char( SIZE(field,2)))// ', nx,ny:' & 574 //trim(to_char(this%griddim%dim%nx))// 'X'//trim(to_char(this%griddim%dim%ny)))
|