Struct solana_ledger::shred::Shredder
source · pub struct Shredder { /* private fields */ }
Implementations§
source§impl Shredder
impl Shredder
pub fn new( slot: Slot, parent_slot: Slot, reference_tick: u8, version: u16 ) -> Result<Self, Error>
pub fn entries_to_shreds( &self, keypair: &Keypair, entries: &[Entry], is_last_in_slot: bool, chained_merkle_root: Option<Hash>, next_shred_index: u32, next_code_index: u32, merkle_variant: bool, reed_solomon_cache: &ReedSolomonCache, stats: &mut ProcessShredsStats ) -> (Vec<Shred>, Vec<Shred>)
sourcepub fn generate_coding_shreds<T: Borrow<Shred>>(
data: &[T],
next_code_index: u32,
reed_solomon_cache: &ReedSolomonCache
) -> Vec<Shred>
pub fn generate_coding_shreds<T: Borrow<Shred>>( data: &[T], next_code_index: u32, reed_solomon_cache: &ReedSolomonCache ) -> Vec<Shred>
Generates coding shreds for the data shreds in the current FEC set
pub fn try_recovery( shreds: Vec<Shred>, reed_solomon_cache: &ReedSolomonCache ) -> Result<Vec<Shred>, Error>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Shredder
impl RefUnwindSafe for Shredder
impl Send for Shredder
impl Sync for Shredder
impl Unpin for Shredder
impl UnwindSafe for Shredder
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 moresource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request