pub trait IsMiningUpstream<Down: IsMiningDownstream, Sel: DownstreamMiningSelector<Down> + ?Sized>: IsUpstream<Down, Sel> {
    // Required methods
    fn total_hash_rate(&self) -> u64;
    fn add_hash_rate(&mut self, to_add: u64);
    fn get_opened_channels(&mut self) -> &mut Vec<UpstreamChannel>;
    fn update_channels(&mut self, c: UpstreamChannel);

    // Provided method
    fn is_header_only(&self) -> bool { ... }
}
Expand description

General properties that every Sv2 compatible mining upstream nodes must implement.

Required Methods§

source

fn total_hash_rate(&self) -> u64

should return total hash rate local to the node

source

fn add_hash_rate(&mut self, to_add: u64)

source

fn get_opened_channels(&mut self) -> &mut Vec<UpstreamChannel>

source

fn update_channels(&mut self, c: UpstreamChannel)

Provided Methods§

Implementations on Foreign Types§

source§

impl<Down: IsMiningDownstream + D> IsMiningUpstream<Down, NullDownstreamMiningSelector> for ()

Implementors§