pub struct RecoveryDecoderResult<'a> { /* private fields */ }Expand description
The restored shards from a successful Decoder::decode_with_recovery, exposing both the
restored original shards (like DecoderResult) and the reconstructed recovery shards.
Implementations§
Source§impl RecoveryDecoderResult<'_>
impl RecoveryDecoderResult<'_>
Sourcepub fn original(&self, index: usize) -> Option<&[u8]>
pub fn original(&self, index: usize) -> Option<&[u8]>
Returns the restored original shard with the given index, or None if it was provided or
index is out of range. See DecoderResult::original.
Sourcepub const fn original_iter(&self) -> Originals<'_> ⓘ
pub const fn original_iter(&self) -> Originals<'_> ⓘ
Returns an iterator over the restored original shards and their indexes, ordered by index.
See DecoderResult::original_iter.
Sourcepub fn recovery(&self, index: usize) -> Option<&[u8]>
pub fn recovery(&self, index: usize) -> Option<&[u8]>
Returns the reconstructed recovery shard with the given index, or None if it was provided
or index is out of range.
Sourcepub const fn recovery_iter(&self) -> Recoveries<'_> ⓘ
pub const fn recovery_iter(&self) -> Recoveries<'_> ⓘ
Returns an iterator over the reconstructed recovery shards and their indexes, ordered by index.
Auto Trait Implementations§
impl<'a> !UnwindSafe for RecoveryDecoderResult<'a>
impl<'a> Freeze for RecoveryDecoderResult<'a>
impl<'a> RefUnwindSafe for RecoveryDecoderResult<'a>
impl<'a> Send for RecoveryDecoderResult<'a>
impl<'a> Sync for RecoveryDecoderResult<'a>
impl<'a> Unpin for RecoveryDecoderResult<'a>
impl<'a> UnsafeUnpin for RecoveryDecoderResult<'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