Skip to main content

vfsi_sync/
lib.rs

1//! Synchronous filesystem contracts.
2//!
3//! Application code uses [`Vfsi`] and [`VfsiExt`]. Backend implementers use
4//! [`backend::HandleBackend`] and [`backend::VectorBackend`]; shared defaults
5//! live in [`backend::helpers`].
6
7pub use vfsi_core::*;
8
9#[doc(hidden)]
10pub mod path {
11    pub use vfsi_core::path::*;
12}
13
14mod traits;
15pub use traits::{BackendDirectoryPage, DirPageCursor, DirectoryPage, ReadAllOptions};
16mod application_macros;
17mod client;
18mod traversal;
19pub use client::{FsClient, FsDir, FsRead, FsReadInto, FsWrite, OpenFile};
20pub use traversal::walk_events;
21/// Native execution contracts for backend implementers and language bindings.
22/// Application callers use [`Vfsi`] and [`VfsiExt`].
23pub mod backend;
24
25#[cfg(feature = "test-support")]
26#[doc(hidden)]
27pub mod test_support;
28
29// Preserve backend-facing paths while the canonical portable types live in core.
30pub use vfsi_core::api::{
31    DEFAULT_DIRECTORY_MAX_ENTRIES, DEFAULT_DIRECTORY_MAX_PATH_BYTES,
32    DEFAULT_READ_ALLV_MAX_TOTAL_BYTES, DEFAULT_READ_MAX_BYTES, DEFAULT_READ_STREAM_CHUNK_BYTES,
33    DEFAULT_READV_MAX_TOTAL_BYTES, DEFAULT_WALK_MAX_DEPTH, DepthLimit, DirectoryListing,
34    ListDirOptions, OpenOptions, ReadIntoResult as FsReadIntoResult, ReadOptions, ResourceLimits,
35    StreamCompletion, StreamOptions, TraversalCompletion, WalkControl, WalkEvent, WalkEventKind,
36    WriteResult as FsWriteResult,
37};
38
39#[doc(hidden)]
40pub mod application;
41
42pub use vfsi_core::api::internal::OwnedReadResult as FsReadResult;