fdds_isreg - is DDS binary data a regular file


SYNOPSIS

#include <fdds.h> (fixed-format sources)
#include <f90dds.h> (free-format sources)

integer function fdds_isreg(bin)

integer bin

DESCRIPTION

This function returns positive value if the binary data is associated with a regular file, otherwise a zero value is returned, indicating that it may be data associated with a pipe, FIFO, socket, character-special file or block-special file. Only if a file is regular can it be seek'd upon.

INPUT

bin is a binary tag, previously obtained from fdds_open. It specifies a particular binary stream.

OUTPUT

A negative value is returned if bin is invalid. Otherwise, the value will indicated whether the file is regular or not by a '0' for 'false' and a positive value for 'true'.

EXAMPLES

      integer bin
      ...
      if (fdds_isreg(in_bin).gt.0) ier=fdds_lseek(bin, 0, -1, SEEK_CUR)
      ...
    

AUTHOR

Jerry Ehlers, BP America (May 2003)