Trait iota_types::committee::CommitteeTrait
source · pub trait CommitteeTrait<K: Ord> {
// Required methods
fn shuffle_by_stake_with_rng(
&self,
preferences: Option<&BTreeSet<K>>,
restrict_to: Option<&BTreeSet<K>>,
rng: &mut impl Rng,
) -> Vec<K>;
fn weight(&self, author: &K) -> StakeUnit;
// Provided method
fn shuffle_by_stake(
&self,
preferences: Option<&BTreeSet<K>>,
restrict_to: Option<&BTreeSet<K>>,
) -> Vec<K> { ... }
}
Required Methods§
fn shuffle_by_stake_with_rng( &self, preferences: Option<&BTreeSet<K>>, restrict_to: Option<&BTreeSet<K>>, rng: &mut impl Rng, ) -> Vec<K>
fn weight(&self, author: &K) -> StakeUnit
Provided Methods§
fn shuffle_by_stake( &self, preferences: Option<&BTreeSet<K>>, restrict_to: Option<&BTreeSet<K>>, ) -> Vec<K>
Object Safety§
This trait is not object safe.