Skip to main content

Crate haz_vfs

Crate haz_vfs 

Source
Expand description

Filesystem port used by every filesystem-touching crate in haz.

haz-vfs is the hexagonal port: it defines the Filesystem trait, its supporting value types, and the FsError variant set every implementation produces. The production implementation StdFilesystem ships with the crate; an in-memory implementation for tests lives in the haz-vfs-testing crate.

  • StdFilesystem for production code. Delegates straight to std::fs and inherits the host platform’s symlink, depth-cap, and canonicalisation semantics.

Consumers (haz-discovery, haz-cache, haz-exec) borrow a Filesystem implementation generically rather than depending on a concrete impl.

Re-exports§

pub use std_impl::StdCanonicalPath;
pub use std_impl::StdFilesystem;
pub use traits::DirEntry;
pub use traits::EntryKind;
pub use traits::Filesystem;
pub use traits::FsError;
pub use traits::FsMetadata;
pub use traits::WritableFilesystem;

Modules§

std_impl
Real-filesystem implementation of Filesystem.
traits
Filesystem trait, its supporting value types, and the FsError variant set every implementation produces.