My Project
Public Member Functions | List of all members
mod_nctools::nc_make_runtime_att_chr Interface Reference

Public Member Functions

type(ncatt) function, pointer nc_make_runtime_att_chr_scl (NAME, VALUES)
 
type(ncatt) function, pointer nc_make_runtime_att_chr_vec (NAME, VALUES)
 

Detailed Description

Definition at line 64 of file mod_nctools.f90.

Member Function/Subroutine Documentation

◆ nc_make_runtime_att_chr_scl()

type(ncatt) function, pointer mod_nctools::nc_make_runtime_att_chr::nc_make_runtime_att_chr_scl ( character(len=*), intent(in)  NAME,
character(len=*), intent(in)  VALUES 
)

Definition at line 662 of file mod_nctools.f90.

662  ! NAME IS FIXED, BUT VALUES ARE SENT BY MPI IF NEEDED
663  USE control
664  IMPLICIT NONE
665  TYPE(NCATT), POINTER :: ATT
666  character(len=*), intent(in) :: name
667  character(len=*), intent(in) :: VALUES
668  integer :: ierr, len, DEST,SOURCE
669  integer, parameter :: tag = 40004
670 
671  att => new_att()
672 
673  att%attid = -1
674  att%ATTname = trim(name)
675  att%xtype = nf90_char
676 
677  IF (.NOT. ioproc) THEN
678  ALLOCATE(att%CHR(1))
679  att%CHR = trim(values)
680  att%LEN = len_trim(values)
681  END IF
682 
683  IF (use_mpi_io_mode) THEN
684  END IF
685 
686  IF(att%len==0) CALL kill_att(att)
687 
688 
logical use_mpi_io_mode
Definition: mod_main.f90:188
logical ioproc
Definition: mod_main.f90:103

◆ nc_make_runtime_att_chr_vec()

type(ncatt) function, pointer mod_nctools::nc_make_runtime_att_chr::nc_make_runtime_att_chr_vec ( character(len=*), intent(in)  NAME,
character(len=*), dimension(:), intent(in), allocatable  VALUES 
)

Definition at line 693 of file mod_nctools.f90.

693  ! NAME IS FIXED, BUT VALUES ARE SENT BY MPI IF NEEDED
694  USE control
695  IMPLICIT NONE
696  TYPE(NCATT), POINTER :: ATT
697  character(len=*), intent(in) :: name
698  character(len=*),ALLOCATABLE, intent(in) :: VALUES(:)
699  integer :: ierr, len, DEST,SOURCE,I,csize
700  integer, parameter :: tag = 40004
701 
702 ! if(len_trim(VALUES) .GT. Char_max_attlen) &
703 ! & Call fatal_error("Can not make attribute: "//trim(NAME),&
704 ! &"attribute string is too long. Increase 'char_max_attlen' in mod_ncll.F")
705  att => new_att()
706 
707  att%attid = -1
708  att%ATTname = trim(name)
709  att%xtype = nf90_char
710 
711  IF (.NOT. ioproc .and. allocated(values)) THEN
712  ALLOCATE(att%CHR(SIZE(values)))
713  att%CHR = values
714  att%LEN = -1
715  END IF
716 
717  IF (use_mpi_io_mode) THEN
718  END IF
719 
720  IF(.not.allocated(att%chr)) call kill_att(att)
721 
722 
logical use_mpi_io_mode
Definition: mod_main.f90:188
logical ioproc
Definition: mod_main.f90:103

The documentation for this interface was generated from the following file: