AUDIO
Source snapshot · 12 October 2026

API reference / ravet_runtime::files

Module files 

Expand description

Bounded control-file reads and atomic replacement, independent of product paths.

Enums§

FileError
No partial read is returned on error.

Functions§

atomic_write
Create parent directories, write an exclusive same-directory temporary, flush its content, then atomically replace the destination on supported OSes. A failed replacement preserves the old destination and cleans the temporary. Does not sync the parent directory or promise power-loss durability.
read
Read binary bytes up to a caller-supplied limit. Empty files succeed; missing files fail. Checks the actual stream, including a growing file.
read_bounded
Apply the same bound to any reader; reads at most one byte beyond the limit.