IOInterp:
CEDAR
DEFINITIONS =
BEGIN
STREAM: TYPE = IO.STREAM;
Value: TYPE = IO.Value;
ROPE: TYPE = Rope.ROPE;
UnsafeBlock: TYPE = IO.UnsafeBlock;
GetChar: PROC[self: STREAM] RETURNS [CHAR];
GetBlock:
PROC [self:
STREAM, block:
REF
TEXT,
startIndex: NAT ← 0, count: NAT ← NAT.LAST]
RETURNS [nBytesRead: NAT];
UnsafeGetBlock:
UNSAFE
PROC [self:
STREAM, block: UnsafeBlock]
RETURNS [nBytesRead: INT];
EndOf: PROC [self: STREAM] RETURNS [BOOL];
CharsAvail: PROC [self: STREAM, wait: BOOL ← FALSE] RETURNS [INT];
Backup: PROC [self: STREAM, char: CHAR];
PutChar: PROC [self: STREAM, char: CHAR];
PutBlock: PROC [self: STREAM, block: REF READONLY TEXT, startIndex: NAT ← 0, count: NAT ← NAT.LAST];
UnsafePutBlock: UNSAFE PROC [self: STREAM, block: UnsafeBlock];
Flush: PROC [self: STREAM];
Reset: PROC [self: STREAM];
Close: PROC [self: STREAM, abort: BOOL ← FALSE];
GetIndex: PROC[self: STREAM] RETURNS [index: INT];
SetIndex: PROC[self: STREAM, index: INT];
TextFromTOS: PROC [self: STREAM] RETURNS [REF TEXT];
atom: PROC [v: ATOM] RETURNS [Value];
bool: PROC [v: BOOL] RETURNS [Value];
card: PROC [v: LONG CARDINAL] RETURNS [Value];
char: PROC [v: CHAR] RETURNS [Value];
int: PROC [v: INT] RETURNS [Value];
real: PROC [v: REAL] RETURNS [Value];
refAny: PROC [v: REF READONLY ANY] RETURNS [Value];
rope: PROC [v: ROPE] RETURNS [Value];
text: PROC [v: REF READONLY TEXT] RETURNS [Value];
time: PROC [v: BasicTime.GMT ← BasicTime.nullGMT] RETURNS [Value];
FSStreamOpen: PROC [fileName: ROPE, accessOptions: FS.AccessOptions ← $read, streamOptions: REF FS.StreamOptions ← NIL, keep: CARDINAL ← 1, createByteCount: FS.ByteCount ← 2560, streamBufferParms: REF FS.StreamBufferParms ← NIL] RETURNS [STREAM];
END.