    module io
! IO - unit numbers for the data analysis subroutines.
!
!  SYNOPSIS
!     use io
!
!  DEPENDENCIES
!     None.
!   
!  MODIFICATION HISTORY
!  08/08/05 - Added dump unit for optional debugging.
!  07/22/04 - Revised by Eric to clean up swapped and unswapped units.
!
!  IN and OUT correspond to the standard input and output.
!  IERR is the standard error.  These are intended for use with text i/o.
!  Unit 0 is an extension of the Fortran standard, but it is commonly used
!  for the standard error.  However, I know of one implementation where
!  the standard error is mapped to unit 7.  Alter as appropriate.
!
    integer,parameter::IN=5,IOUT=6,IERR=0
!
!  DIAGUNIT is reserved for the output of diagnostics related
!  to the data assimilation method.  This is intended for text output.
!
    integer,parameter::DIAGUNIT=8
!
!  Logical unit to which we write a log of our actions if verbose
!  output is requested.  In this implementation, the log file coincides
!  with the standard output.
!
    integer,parameter::LOGFILE=IOUT
!
!  Four units are used for input and output of binary data, depending
!  on whether byte-swapping may be required.
!  if desired.
!
    integer,parameter::INSWAP=1,OUTSWAP=2,INNOSWAP=3,OUTNOSWAP=4
!
!  Dump unit for debug output; this may be either formatted or unformatted,
!  though care must be taken in the latter case because of endian issues.
!
    integer,parameter::DUMPUNIT=5
!
!  MAX_FILE_NAME_LEN is the length of the longest supported filename
!  in this implementation.
!
    integer,parameter::MAX_FILE_NAME_LEN=128
    end module io
