pub struct BlockDepthManager<S: DepthStoreReader, U: ReachabilityStoreReader, V: GhostdagStoreReader> { /* private fields */ }Implementations§
Source§impl<S: DepthStoreReader, U: ReachabilityStoreReader, V: GhostdagStoreReader> BlockDepthManager<S, U, V>
impl<S: DepthStoreReader, U: ReachabilityStoreReader, V: GhostdagStoreReader> BlockDepthManager<S, U, V>
pub fn new( merge_depth: u64, finality_depth: u64, genesis_hash: Hash, depth_store: Arc<S>, reachability_service: MTReachabilityService<U>, ghostdag_store: Arc<V>, ) -> Self
pub fn calc_merge_depth_root( &self, ghostdag_data: &GhostdagData, pruning_point: Hash, ) -> Hash
pub fn calc_finality_point( &self, ghostdag_data: &GhostdagData, pruning_point: Hash, ) -> Hash
Sourcepub fn kosherizing_blues<'a>(
&'a self,
ghostdag_data: &'a GhostdagData,
merge_depth_root: Hash,
) -> impl DoubleEndedIterator<Item = Hash> + 'a
pub fn kosherizing_blues<'a>( &'a self, ghostdag_data: &'a GhostdagData, merge_depth_root: Hash, ) -> impl DoubleEndedIterator<Item = Hash> + 'a
Returns the set of blues which are eligible for “kosherizing” merge bound violating blocks.
By prunality rules, these blocks must have merge_depth_root on their selected chain.
Trait Implementations§
Source§impl<S: Clone + DepthStoreReader, U: Clone + ReachabilityStoreReader, V: Clone + GhostdagStoreReader> Clone for BlockDepthManager<S, U, V>
impl<S: Clone + DepthStoreReader, U: Clone + ReachabilityStoreReader, V: Clone + GhostdagStoreReader> Clone for BlockDepthManager<S, U, V>
Source§fn clone(&self) -> BlockDepthManager<S, U, V>
fn clone(&self) -> BlockDepthManager<S, U, V>
Returns a duplicate of the value. Read more
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl<S, U, V> Freeze for BlockDepthManager<S, U, V>
impl<S, U, V> !RefUnwindSafe for BlockDepthManager<S, U, V>
impl<S, U, V> Send for BlockDepthManager<S, U, V>
impl<S, U, V> Sync for BlockDepthManager<S, U, V>
impl<S, U, V> Unpin for BlockDepthManager<S, U, V>
impl<S, U, V> !UnwindSafe for BlockDepthManager<S, U, V>
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<S> CastArc for Swhere
S: CastFromSync + ?Sized,
impl<S> CastArc for Swhere
S: CastFromSync + ?Sized,
Source§impl<T> CastFrom for Twhere
T: Any + 'static,
impl<T> CastFrom for Twhere
T: Any + 'static,
Source§fn ref_any(&self) -> &(dyn Any + 'static)
fn ref_any(&self) -> &(dyn Any + 'static)
Returns a immutable reference to
Any, which is backed by the type implementing this trait.Source§fn mut_any(&mut self) -> &mut (dyn Any + 'static)
fn mut_any(&mut self) -> &mut (dyn Any + 'static)
Returns a mutable reference to
Any, which is backed by the type implementing this trait.Source§impl<T> CastFromSync for T
impl<T> CastFromSync for T
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)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