pub fn new(subnet_size: usize) -> Self {
            let rng = &mut thread_rng();
            let dkg_tag = match rng.gen::<bool>() {
                true => NiDkgTag::LowThreshold,
                false => NiDkgTag::HighThreshold,
            };
            // The registry version is used as DKG epoch and an epoch is u32. Because of
            // this, the maximum registry version we choose is u32::MAX, decreased by a
            // margin that allows for increasing it again sufficiently during tests.
            let registry_version = RegistryVersion::new(rng.gen_range(1, u32::MAX - 10_000) as u64);
            Self::new_with_tag_and_registry_version(subnet_size, dkg_tag, registry_version)
        }
/// Creates a random NI-DKG config satisfying all invariants.
Creates a random NI-DKG config satisfying all invariants.
Creates a random NI - DKG config satisfying all invariants .
pub fn new(subnet_size: usize) -> Self {
            let rng = &mut thread_rng();
            let dkg_tag = match rng.gen::<bool>() {
                true => NiDkgTag::LowThreshold,
                false => NiDkgTag::HighThreshold,
            };
            // The registry version is used as DKG epoch and an epoch is u32. Because of
            // this, the maximum registry version we choose is u32::MAX, decreased by a
            // margin that allows for increasing it again sufficiently during tests.
            let registry_version = RegistryVersion::new(rng.gen_range(1, u32::MAX - 10_000) as u64);
            Self::new_with_tag_and_registry_version(subnet_size, dkg_tag, registry_version)
        }
pub fn new ( subnet_size : usize ) -> Self { let rng = & mut thread_rng ( ) ; let dkg_tag = match rng . gen :: < bool > ( ) { true => NiDkgTag :: LowThreshold , false => NiDkgTag :: HighThreshold , } ; // The registry version is used as DKG epoch and an epoch is u32. Because of // this, the maximum registry version we choose is u32::MAX, decreased by a // margin that allows for increasing it again sufficiently during tests. let registry_version = RegistryVersion :: new ( rng . gen_range ( 1 , u32 :: MAX - 10_000 ) as u64 ) ; Self :: new_with_tag_and_registry_version ( subnet_size , dkg_tag , registry_version ) }
Creates a random NI-DKG config satisfying all invariants.
Creates a random NI - DKG config satisfying all invariants .
subnet_size
usize
subnet_size
usize