Purpose
Set
default input/output streams of a model.
Synopsis
procedure setdefstream(mo:Model, wmd:integer, fname:string)
procedure setdefstream(mo:Model, input:string, output:string, error:string)
Arguments
mo
|
A Model
|
wmd
|
Stream to set. Possible values:
F_INPUT
|
Default input stream
|
F_OUTPUT
|
Default output stream
|
F_ERROR
|
Default error stream
|
F_LINBUF
|
Use line buffering
|
|
fname
|
Extended file name to be used for the stream.
|
input
|
Extended file name to be used for the input stream.
|
output
|
Extended file name to be used for the output stream.
|
error
|
Extended file name to be used for the error stream.
|
Further information
1. This function sets default IO streams to be used by
a model. Model streams can be changed
only when the model is not running. Each stream is associated
to an extended file name (i.e. IO drivers can be used).
For output streams, F_LINBUF may be specified
(e.g.F_WRITE+F_LINBUF) in order to enable
line buffering for the corresponding stream (the
error stream is always open using line buffering).
2.
For input and output streams,
the filename is stored and streams are actually open when execution
of the model starts: in case of an invalid file name, the error is
not reported by this function. The error stream is immediately opened
so in the case of an invalid file name is detected by this function.
3.
Using an empty string as the file name implies resetting to the original
default stream.
If you have any comments or suggestions about these pages,
please send mail to docs@dashoptimization.com.