Home > Class Reference > ENSLIB namespace > %IO.DeviceStream

%IO.DeviceStream

class %IO.DeviceStream extends %IO.I.CharacterStream, %IO.I.TranslationDevice

Property Inventory (Including Private)

Method Inventory (Including Private)

Properties (Including Private)

property %Attached as %Boolean [ Private , Transient , ReadOnly ];
Property methods: %AttachedDisplayToLogical(), %AttachedGet(), %AttachedIsValid(), %AttachedLogicalToDisplay(), %AttachedNormalize()
property %CurrLineTerminator as %String [ Private , Transient , ReadOnly ];
Property methods: %CurrLineTerminatorDisplayToLogical(), %CurrLineTerminatorGet(), %CurrLineTerminatorIsValid(), %CurrLineTerminatorLogicalToDisplay(), %CurrLineTerminatorLogicalToOdbc(), %CurrLineTerminatorNormalize()

Methods (Including Private)

private method %OnClose() as %Status
Inherited description: This callback method is invoked by the %Close() method to provide notification that the current object is being closed.

The return value of this method is ignored.

method Attach(pDevice As %String = $IO, Output pSC As %Status)
Attach to the named open Device or to the current Device by default
classmethod AttachNew(pDevice As %String = $IO, Output pSC As %Status) as %IO.DeviceStream
Attach the current $IO device to an instance of this class
method CharEncodingSet(pCharEncoding As %String) as %Status
method Close(Output pSC As %Status) as %Boolean
Inherited description: Close the current stream
method DefaultFlushOnWriteGet()
method Flush(Output pSC As %Status)
Inherited description: Ensure that any data already written to the stream buffer are actually sent to the stream.
method Read(pMaxReadLen As %Integer, ByRef pTimeout As %Numeric = -1, Output pSC As %Status) as %String
Inherited description: Read until pMaxReadLen chars are gotten or pTimeout expires On return, if pTimeout is unchanged it means the full timeout period expired. If the timeout period expired and the returned string is shorter than pMaxReadLen, then AtEnd will be 1.
method ReadLine(pMaxReadLen As %Integer, ByRef pTimeout As %Numeric = -1, Output pSC As %Status, ByRef pLineTerminator As %String = ..LineTerminator) as %String
Inherited description: 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) as %Status
method Write(pData As %String = "", pFlush As %Boolean = ..DefaultFlushOnWrite, Output pSC As %Status)
Inherited description: Write pData to the stream buffer. If pFlush is True, ensure that the data are actually sent to the stream.
private method initDeviceTranslationTable(Output pSC As %Status)
private classmethod isReadError(pZE As %String) as %Boolean
private classmethod isWriteError(pZE As %String) as %Boolean

Inherited Members

Inherited Properties (Including Private)

Inherited Methods (Including Private)