contentsconceptssyntaxlibrariessampleserrorsindex
Full text search
function   io-exception-text    
      Other Library Functions  

Library: I/O Exception Object
Include: omioe.xin
Returns: String

Returns a string that summarizes the bits set in the "io-exception" object's status.

Declaration

  define stream function io-exception-text
       value io-exception ex


Purpose

This function accepts an "io-exception" object as its sole argument and returns a printable string of text that summarizes the bits set in the io-exception's status.

Argument:

Example:

  ; Using "set-voluntary-end-exception" to recognize and act on a data-encoded
  ; stream end mark (in this case "Control-Z"). The global declaration and
  ; process rule indicate how the source scanned by the find rule, and the
  ; io-exception used by it would be set up.
  ; This example also uses "get-exception-status" and "io-exception-text" to report
  ; errors (exceptions other than the voluntary end) in using the source.

  global io-exception input-exception
  process
     submit input-file "myfile.txt" exceptions-to input-exception
     do when get-exception-status input-exception != (0 | IOException_VoluntaryEOF)
        put #error "Error on myfile.txt:%n" ||
                   io-exception-text get-exception-status input-exception
     done

        Other Library Functions
   get-exception-status
   io-exception-text
   new-io-exception
   set-voluntary-end-exception
 
----  

Top [CONTENTS] [CONCEPTS] [SYNTAX] [LIBRARIES] [SAMPLES] [ERRORS] [INDEX]

Generated: April 21, 1999 at 2:01:08 pm
If you have any comments about this section of the documentation, send email to [email protected]

Copyright © OmniMark Technologies Corporation, 1988-1999.