NCEPLIBS-bufr  12.0.0
readlc.f File Reference

Read a long character string (greater than 8 bytes) from a data subset. More...

Go to the source code of this file.

Functions/Subroutines

recursive subroutine readlc (LUNIT, CHR, STR)
 Read a long character string (greater than 8 bytes) from a data subset. More...
 

Detailed Description

Read a long character string (greater than 8 bytes) from a data subset.

Authors
J. Woollen J. Ator
Date
2003-11-04

Definition in file readlc.f.

Function/Subroutine Documentation

◆ readlc()

recursive subroutine readlc (   LUNIT,
character*(*)  CHR,
character*(*)  STR 
)

Read a long character string (greater than 8 bytes) from a data subset.

The data subset should have already been read into internal arrays via a previous call to one of the subset-reading subroutines.

If there is more than one occurrence of STR within the data subset definition, then each occurrence can be retrieved via a separate call to this subroutine, and by appending the ordinal number of the occurrence to STR in each case.

For example, if there are 5 occurrences of mnemonic LSTID within a given data subset definition, then 5 separate calls should be made to this subroutine, once each with STR set to 'LSTID#1', 'LSTID#2', 'LSTID#3', 'LSTID#4' and 'LSTID#5'.

Omitting the ordinal number always defaults to the first occurrence of a particular string, so a user could just specify 'LSTID' instead of 'LSTID#1'.

Remarks
  • Character strings which are 8 bytes or less in length can be read using the real*8 USR array within a call to one of the BUFRLIB values-reading subroutines and then converting the corresponding real*8 value to character format within the application program.
  • If STR is not found within the data subset definition, then CHR is returned with all bits set to 1, which is the standard WMO BUFR value for "missing" data. Any CHR value returned by this subroutine can be checked for equivalence to this "missing" value via a call to function icbfms().
Parameters
[in]LUNIT- integer: Fortran logical unit number for BUFR file.
[out]CHR- character*(*): Value corresponding to STR.
[in]STR- character*(*): Table B mnemonic of long character. string to be retrieved, possibly supplemented with an ordinal occurrence notation.
Authors
J. Woollen J. Ator
Date
2003-11-04

Definition at line 49 of file readlc.f.

References bort(), moda_rlccmn::crtag, errwrt(), modv_im8b::im8b, moda_usrint::inv, ipkm(), moda_rlccmn::irbit, moda_rlccmn::irnch, moda_tables::itp, moda_bitbuf::mbay, moda_usrbit::mbit, moda_unptyp::msgunp, moda_usrbit::nbit, moda_rlccmn::nrst, moda_usrint::nval, parstr(), parutg(), status(), moda_tables::tag, upc(), and x84().

Referenced by ufbdmp(), ufdump(), and wrtree().