SpillIo

Trait SpillIo 

Source
pub trait SpillIo: Send + Sync {
    // Required methods
    fn create(&self) -> Result<(u64, Box<dyn Write + Send>)>;
    fn open(&self, id: u64) -> Result<Box<dyn Read + Send>>;
    fn remove(&self, id: u64) -> Result<()>;
    fn record_usage(&self, id: u64);
}

Required Methods§

Source

fn create(&self) -> Result<(u64, Box<dyn Write + Send>)>

2026-09-25: A fresh swap file: its id and a writer the device state streams into.

Source

fn open(&self, id: u64) -> Result<Box<dyn Read + Send>>

2026-09-25: The reader for swap file id.

Source

fn remove(&self, id: u64) -> Result<()>

Source

fn record_usage(&self, id: u64)

2026-09-25: Account the finished write of id against the swap budget.

Implementors§