ekv-fs 0.2.0

A chunked, #![no_std] Virtual File System built on top of the Embassy ekv key-value store.
Documentation
//! Error types returned by [`crate::EkvFs`] and [`crate::EkvFile`].

/// Errors that can occur when using the virtual file system.
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub enum Error {
    /// The path exceeds [`crate::EkvFs`]’s `MAX_PATH_LEN` const generic.
    PathTooLong,
    /// A storage key could not be formatted (path too long for key buffer).
    KeyTooLong,
    /// No file exists at the given path.
    NotFound,
    /// The underlying `ekv` database returned an error.
    Database,
    /// Metadata could not be encoded or decoded.
    Serialize,
}

impl Error {
    pub(crate) fn from_db<E>(_: E) -> Self {
        Self::Database
    }
}