binius_core::challenger

Trait CanSample

pub trait CanSample<T> {
    // Required method
    fn sample(&mut self) -> T;

    // Provided methods
    fn sample_array<const N: usize>(&mut self) -> [T; N] { ... }
    fn sample_vec(&mut self, n: usize) -> Vec<T> { ... }
}

Required Methods§

fn sample(&mut self) -> T

Provided Methods§

fn sample_array<const N: usize>(&mut self) -> [T; N]

fn sample_vec(&mut self, n: usize) -> Vec<T>

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

§

impl<'a, C, T> CanSample<T> for &'a mut C
where C: CanSample<T>,

§

fn sample(&mut self) -> T

§

fn sample_array<const N: usize>(&mut self) -> [T; N]

§

fn sample_vec(&mut self, n: usize) -> Vec<T>

Implementors§

source§

impl<F1, Challenger, F2, F2E> CanSample<F2E> for IsomorphicChallenger<F1, Challenger, F2>
where F1: Field + From<F2> + Into<F2>, F2: Field, F2E: ExtensionField<F2>, Challenger: CanSample<F1>,

source§

impl<F, Challenger_> CanSample<F> for TranscriptReader<Challenger_>
where F: TowerField, Challenger_: Challenger,

source§

impl<F, Challenger_> CanSample<F> for TranscriptWriter<Challenger_>
where F: TowerField, Challenger_: Challenger,

§

impl<F, EF, Inner> CanSample<EF> for SerializingChallenger32<F, Inner>
where F: PrimeField32, EF: ExtensionField<F>, Inner: CanSample<u8>,

§

impl<F, EF, Inner> CanSample<EF> for SerializingChallenger64<F, Inner>
where F: PrimeField64, EF: ExtensionField<F>, Inner: CanSample<u8>,

§

impl<F, EF, P, const WIDTH: usize, const RATE: usize> CanSample<EF> for DuplexChallenger<F, P, WIDTH, RATE>
where F: Field, EF: ExtensionField<F>, P: CryptographicPermutation<[F; WIDTH]>,

§

impl<F, EF, PF, P, const WIDTH: usize, const RATE: usize> CanSample<EF> for MultiField32Challenger<F, PF, P, WIDTH, RATE>
where F: PrimeField32, EF: ExtensionField<F>, PF: PrimeField, P: CryptographicPermutation<[PF; WIDTH]>,

source§

impl<F, FE, Impl> CanSample<FE> for FieldChallenger<F, Impl>
where F: Field, FE: ExtensionField<F>, Impl: FieldChallengerHelper<F>,

§

impl<T, H, const OUT_LEN: usize> CanSample<T> for HashChallenger<T, H, OUT_LEN>
where T: Clone, H: CryptographicHasher<T, [T; OUT_LEN]>,