pub struct StatusBuilder { /* private fields */ }Expand description
Builder type for constructing a UnifiedStatus message.
Implementations§
Source§impl StatusBuilder
impl StatusBuilder
Sourcepub const fn build(self) -> UnifiedStatus
pub const fn build(self) -> UnifiedStatus
Consumes the builder and returns the constructed UnifiedStatus.
Sourcepub const fn version(self, version: EthVersion) -> Self
pub const fn version(self, version: EthVersion) -> Self
Sets the eth protocol version (e.g., eth/66, eth/70).
Sourcepub const fn forkid(self, forkid: ForkId) -> Self
pub const fn forkid(self, forkid: ForkId) -> Self
Sets the fork ID, used for fork compatibility checks.
Sourcepub const fn total_difficulty(self, td: Option<U256>) -> Self
pub const fn total_difficulty(self, td: Option<U256>) -> Self
Sets the total difficulty, if relevant (Some for eth/66–68).
Sourcepub const fn earliest_block(self, earliest: Option<u64>) -> Self
pub const fn earliest_block(self, earliest: Option<u64>) -> Self
Sets the earliest available block, if known (Some for eth/69).
Sourcepub const fn latest_block(self, latest: Option<u64>) -> Self
pub const fn latest_block(self, latest: Option<u64>) -> Self
Sets the latest known block, if known (Some for eth/69).
Trait Implementations§
Source§impl Debug for StatusBuilder
impl Debug for StatusBuilder
Auto Trait Implementations§
impl Freeze for StatusBuilder
impl RefUnwindSafe for StatusBuilder
impl Send for StatusBuilder
impl Sync for StatusBuilder
impl Unpin for StatusBuilder
impl UnsafeUnpin for StatusBuilder
impl UnwindSafe for StatusBuilder
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> 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§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
§impl<T> WithSubscriber for T
impl<T> WithSubscriber for T
§fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘwhere
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘwhere
S: Into<Dispatch>,
§fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ
fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 176 bytes