pub struct CheckWriter<'a> { /* private fields */ }
Expand description
Similar to MultiWriter expect for CheckWriter::commit.
Implementations§
source§impl<'a> CheckWriter<'a>
impl<'a> CheckWriter<'a>
sourcepub fn add_check_version(
&mut self,
path: &str,
version: i32,
) -> Result<(), Error>
pub fn add_check_version( &mut self, path: &str, version: i32, ) -> Result<(), Error>
Same as MultiWriter::add_check_version.
sourcepub fn add_create(
&mut self,
path: &str,
data: &[u8],
options: &CreateOptions<'_>,
) -> Result<(), Error>
pub fn add_create( &mut self, path: &str, data: &[u8], options: &CreateOptions<'_>, ) -> Result<(), Error>
Same as MultiWriter::add_create.
sourcepub fn add_set_data(
&mut self,
path: &str,
data: &[u8],
expected_version: Option<i32>,
) -> Result<(), Error>
pub fn add_set_data( &mut self, path: &str, data: &[u8], expected_version: Option<i32>, ) -> Result<(), Error>
Same as MultiWriter::add_set_data.
sourcepub fn add_delete(
&mut self,
path: &str,
expected_version: Option<i32>,
) -> Result<(), Error>
pub fn add_delete( &mut self, path: &str, expected_version: Option<i32>, ) -> Result<(), Error>
Same as MultiWriter::add_delete.
sourcepub fn commit(
self,
) -> impl Future<Output = Result<Vec<MultiWriteResult>, CheckWriteError>> + Send + 'a
pub fn commit( self, ) -> impl Future<Output = Result<Vec<MultiWriteResult>, CheckWriteError>> + Send + 'a
Similar to MultiWriter::commit except independent path check error.
Auto Trait Implementations§
impl<'a> Freeze for CheckWriter<'a>
impl<'a> !RefUnwindSafe for CheckWriter<'a>
impl<'a> Send for CheckWriter<'a>
impl<'a> Sync for CheckWriter<'a>
impl<'a> Unpin for CheckWriter<'a>
impl<'a> !UnwindSafe for CheckWriter<'a>
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more