class %IO.DeviceStream
extends %IO.I.CharacterStream, %IO.I.TranslationDevice
method Attach(pDevice As %String = $IO, Output pSC As %Status)
returns nothing.
Attach to the named open Device or to the current Device by default
classmethod AttachNew(pDevice As %String = $IO, Output pSC As %Status)
returns %IO.DeviceStream
Attach the current $IO device to an instance of this class
method CharEncodingSet(pCharEncoding As %String)
returns %Status
method Close(Output pSC As %Status)
returns %Boolean
method Flush(Output pSC As %Status)
returns nothing.
method Read(ByRef pLen As %Integer = ..#MAXLOCALSTRING, ByRef pTimeout As %Numeric = -1, Output pSC As %Status)
returns %String
Read until pMaxReadLen chars are gotten or pTimeout expires
On return, if pTimeout=0 it means no timeout occurred. If pTimeout=0 and the returned string is shorter than pMaxReadLen, then AtEnd will be 1.
method ReadLine(pMaxReadLen As %Integer = ..#MAXLOCALSTRING, ByRef pTimeout As %Numeric = -1, Output pSC As %Status, ByRef pLineTerminator As %String = ..LineTerminator)
returns %String
Read until pMaxReadLen chars are gotten, pTimeout expires, or a LineTerminator character is found.
On return, if pTimeout=0 it means no timeout occurred. If pTimeout=0 and the returned string contains the full pMaxReadLen characters, it means no LineTerminator was encountered yet, even if the following character would be a LineTerminator.
If pTimeout=0 and the returned string is shorter than pMaxReadLen, then either a LineTerminator or the End Of Stream (AtEnd = 1) was encountered.
If pLineTerminator is defined, then the line is read until one of the given characters is encountered. On return, pLineTerminator contains the encountered character(s) if any.
method TranslationTableSet(pTable As %String)
returns %Status
method Write(pData As %String = "", pFlush As %Boolean = ..#DEFAULTFLUSHONWRITE, Output pSC As %Status)
returns nothing.