Skip to main content

Module file

Module file 

Source
Expand description

File reading, writing, and streaming.

Structs§

File
An open file handle without access to platform-specific filesystem APIs.

Constants§

EXECUTABLE_MODE 🔒

Functions§

create
Create or truncate a file for streaming writes.
create_new
Create a new file without replacing an existing entry.
open
Open a file for reading.
read_bytes
Read an entire file as bytes.
read_text
Read an entire UTF-8 text file.
read_text_if_exists
Read an entire UTF-8 text file when it exists.
write_bytes
Replace a file’s contents directly.
write_text
Replace a UTF-8 text file’s contents directly.