Skip to main content

FileWriter

Trait FileWriter 

Source
pub trait FileWriter: Write + Send {
    // Required methods
    fn commit(self: Box<Self>) -> FsResult<WriteOutcome>;
    fn abort(self: Box<Self>) -> FsResult<()>;
}
Expand description

Write handle returned by filesystem implementations.

Required Methods§

Source

fn commit(self: Box<Self>) -> FsResult<WriteOutcome>

Commits the write operation.

§Returns

Write outcome reported by the provider.

§Errors

Returns crate::FsError when the provider cannot commit the write.

Source

fn abort(self: Box<Self>) -> FsResult<()>

Aborts the write operation.

§Errors

Returns crate::FsError when the provider cannot abort or clean up the write session.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§