NCEPLIBS-bufr 11.7.1
readns.f File Reference

Read the next data subset from a BUFR file that was previously opened for reading. More...

Go to the source code of this file.

Functions/Subroutines

subroutine readns (LUNIT, SUBSET, JDATE, IRET)
 This subroutine provides a handy way to combine the functionality of subroutines readmg() and readsb() within a single subroutine call. More...
 

Detailed Description

Read the next data subset from a BUFR file that was previously opened for reading.

Definition in file readns.f.

Function/Subroutine Documentation

◆ readns()

subroutine readns (   LUNIT,
character*8  SUBSET,
  JDATE,
  IRET 
)

This subroutine provides a handy way to combine the functionality of subroutines readmg() and readsb() within a single subroutine call.

Author
J. Woollen
Date
1994-01-06
Parameters
[in]LUNIT– integer: Fortran logical unit number for BUFR file
[out]SUBSET– character*8: Table A mnemonic for type of data subset that was read (see DX BUFR Tables for further information about Table A mnemonics)
[out]JDATE– integer: Date-time stored within Section 1 of BUFR message containing data subset that was read, in format of either YYMMDDHH or YYYYMMDDHH, depending on the most recent call to subroutine datelen()
[out]IRET– integer: return code
  • 0 = new BUFR data subset was successfully read into internal arrays
  • -1 = there are no more BUFR data subsets in the file connected to logical unit LUNIT

Logical unit LUNIT should have already been opened for input operations via a previous call to subroutine openbf(). But once that is done, the application program can immediately call this subroutine to read each new data subset from the associated BUFR file, and the subroutine will automatically open and close each new BUFR message internally as needed, so that subsequent calls can immediately be made to any of the various values-reading subroutines.

Program history log:

Date Programmer Comments
1994-01-06 J. Woollen Original author
1998-07-08 J. Woollen Replaced call to Cray library routine "ABORT" with call to new internal routine bort(); modified to make Y2K compliant
1999-11-18 J. Woollen The number of BUFR files which can be opened at one time increased from 10 to 32
2003-11-04 D. Keyser MAXJL (maximum number of jump/link entries) increased from 15000 to 16000
2014-12-10 J. Ator Use modules instead of COMMON blocks

Definition at line 48 of file readns.f.

References bort(), readmg(), readsb(), status(), and moda_tables::tag.

Referenced by ireadns().