| Syntax 
   declare no-default-io
 
 Purpose
 
 The no-default-iodeclaration is provided to make it easier for you to develop server and similar transaction-based applications in OmniMark. This declaration keeps the programs in which it is used from using environment features such as "standard input" and "standard output", because these features differ in their behavior between batch processing and server environments. Theno-default-iodeclaration allows you to maintain consistency in how these different types of programs run. Sinceno-default-ioprograms don't have any established input sources or output destinations, these sources and destinations must be explicitly established within the program. Note that the no-default-iodeclaration cannot be used in any of the aided translation type programs. Since no-default-ioprograms do not have any established input sources or output destinations, the following streams cannot be used: Additionally, neither the #process-inputnor#main-inputsource can be used. The#command-line-namesshelf is still available inno-default-ioprograms, but#main-inputis not bound to the files named in that shelf as it is in other programs. Since the current output set (#current-output) is not initially established, it is an error to use anoutputaction or to make any reference to#current-outputuntil a current output set is established. Note that the#current-output is attachedtest is now available, allowing you to determine the current state of#current-outputprior to writing to it. Error and status reporting in a no-default-ioprogram cannot be done by writing to#errorbecause any reference to this stream is an error. OmniMark provides thelog-messagefunction (part of the #builtin function library) as a general mechanism for error and status reporting in ano-default-ioprogram. |