"File-access + extensions"file
The Optional File-Access Word Set and
File-Access Extension Words.
These words imply some kind of file-system unlike
the BLOCK wordset.
[ANS]
modify the give file access-mode to be a binary-mode
| file ordinary primitive
close the file and return the status-code
| file ordinary primitive
create the file with the given name and open
it - returns the file id and a status code.
A code of zero means success. An existing file
of the same name is truncated upon open.
| file ordinary primitive
delete the named file and return a status code
| file ordinary primitive
return the current position in the file and
return a status code. A code of zero means success.
| file ordinary primitive
return the current size of the file and
return a status code. A code of zero means success.
| file ordinary primitive
file ordinary primitive
file ordinary primitive
open the named file with mode. returns the
file id and a status code. A code of zero
means success.
| file ordinary primitive
file ordinary constant
file ordinary constant
fill the given string buffer with characters
from the buffer. A status code of zero means
success and the returned count gives the
number of bytes actually read. If an error
occurs the number of already transferred bytes
is returned.
| file ordinary primitive
fill the given string buffer with one line
from the file. A line termination character
(or character sequence under WIN/DOS) may
also be placed in the buffer but is not
included in the final count. In other respects
this function performs a READ-FILE
| file ordinary primitive
reposition the file offset - the next FILE-POSITION
would return o.offset then. returns a status code.
| file ordinary primitive
resize the give file, returns a status code.
| file ordinary primitive
file ordinary constant
write characters from the string buffer to a file,
returns a status code.
| file ordinary primitive
write characters from the string buffer to a file,
and add the line-terminator to the end of it.
returns a status code.
| file ordinary primitive
check the named file - if it exists
the status code is zero. The sub-code
is implementation-specific.
| file ordinary primitive
flush all unsaved buffers of the file to disk.
A status code of zero means success.
| file ordinary primitive
rename the file named by string1 to the name of string2.
returns a status-code
| file ordinary primitive
ENVIRONMENT
ENVIRONMENT FILE-EXT no special info, see general notes file ordinary constant
the number of opened file-ids allowed during compilation.
portable programs can check this with ENVIRONMENT?
| file ordinary primitive
|