pub struct RecoveryDecoderResult<'a> { /* private fields */ }Expand description
The restored shards from a successful Decoder::decode_with_recovery or
Decoder::decode_with_recovery_plan, 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