io.files vocabulary
Factor handbook ยป Vocabulary index


Documentation
Reading and writing files

Metadata
Authors:Slava Pestov, Daniel Ehrenberg


Words

Tuple classes
ClassSuperclassSlots
no-such-file tuplepath


Mixin classes
file-reader
file-writer


Generic words
WordStack effect
(file-appender)( path -- stream )
(file-reader)( path -- stream )
(file-writer)( path -- stream )
(file-writer-secure)( path -- stream )
drain( port handle -- event/f )
refill( port handle -- event/f )
wait-for-fd( handle event -- )


Symbol words
+input+
+output+
+retry+


Ordinary words
WordStack effect
<file-appender>( path encoding -- stream )
<file-reader>( path encoding -- stream )
<file-writer-secure>( path encoding -- stream )
<file-writer>( path encoding -- stream )
change-file-contents( ..a path encoding quot: ( ..a seq -- ..b seq' ) -- ..b )
change-file-lines( ..a path encoding quot: ( ..a seq -- ..b seq' ) -- ..b )
check-file-exists( path -- path )
file-contents( path encoding -- seq )
file-exists?( path -- ? )
file-lines( path encoding -- seq )
if-file-exists( ..a path true: ( ..a path -- ..b ) false: ( ..a path -- ..b ) -- ..b )
init-resource-path( -- )
no-such-file( path -- * )
set-file-contents( seq path encoding -- )
set-file-lines( seq path encoding -- )
unless-file-exists( ... path quot: ( ... path -- ... ) -- ... )
when-file-exists( ... path quot: ( ... path -- ... ) -- ... )
with-file-appender( path encoding quot -- )
with-file-reader( path encoding quot -- )
with-file-writer( path encoding quot -- )
with-file-writer-secure( path encoding quot -- )


Class predicate words
WordStack effect
file-reader?( object -- ? )
file-writer?( object -- ? )
no-such-file?( object -- ? )


Files


Metadata files


Children from resource:basis
VocabularySummary
io.files.infoFile and file system metadata
io.files.linksWorking with symbolic links
io.files.temp
io.files.typesFile types for file-info and directory listing
io.files.uniqueTemporary files with unique names
io.files.unixImplementation of reading and writing files on Unix-like systems
io.files.windows


Children from resource:extra
VocabularySummary
io.files.acls
io.files.trashSend files to the trash bin.


Children
VocabularySummary
io.files.private