exists filename:String
REPLY Boolean
Reply TRUE if filename exists in operating system
delete filename:String
REPLY String
Delete filename from the operating system. I don't know why it replies with a string.
open filename:String for mode:Integer
Open filename for #reading, #writing or #appending.
SIGNAL "Invalid mode for File".
fopen filename:String mode mode:Integer
REPLY Integer
Actually open filename with mode. Reply with an integer status.
read n:Integer
REPLY String
Reply with the next n characters from me.
write data:String
Write data on to me.
close
Close me.
newstring source:String
Reply with an internal stream and initialize with source.
newfile filename:String
Reply with an external stream which uses filename as its source.
charsLeft
REPLY Integer
Reply with the number of characters left in data. There may be more characters in the file.
upToEnd
REPLY String
Reply with the string of characters left to read. There may be more characters in the file.
next
REPLY Integer
Reply with the next character to read and advance marker.
peek
REPLY Integer
Reply with the next character to read but don't advance marker.
advance n:Integer
Advance the marker n characters.
get n:Integer
REPLY String
Get the next n characters.
put n:Integer
Back up the marker n characters.
skipSpaces
Advance the marker to the next no space character. Space characters are space, newline, formfeed and tab.
getWordDelimitedBy delim:String
REPLY String
Get the next word up to a character found in delim.
getWord
REPLY String
Get the next word up to a space tab or new line.
getQuotedString ch:Integer
REPLY String
Get the next string surrounded by the ch character.
SIGNAL "Missing ''''"
getInteger
REPLY Integer
Reply with the next integer in the input.
getLine
REPLY String
Reply with the next line in the input. A line is terminated by a newline character. The returned line does not include the newline. NIL is returned if me is already at the end of the input.
atEnd
REPLY Boolean
Reply TRUE if me is at the end of the input.
close
Close the file if one was being used.
newfile filename:String width size:Integer
Reply with a new stream with filename and width.
newstring size:Integer
Reply with a new internal stream and width size.
print s:String
Append s to current output line. If length of line exceeds width, find space to break output line and append to text array for internal stream, or to file for file stream.
printLine s:String
Append s to current line and create a new line.
newline
Append output line to output and start new line.
close
REPLY Array
Close any open file for a file stream or reply with the array of strings for internal stream.
new
Reply with an empty buffer of 50 characters.
printChar aChar:Integer
Put aChar at the next location in the buffer and resize if needed.
SIGNAL "Buffer overflow"
printString aString:String
Put the characters in aString at the next locations in the buffer.
initialize
Initialize the buffer to 50 characters.
asString
REPLY String
Reply with the current value of the buffer.