pub struct ScalarStrategy {}
👎Deprecated: This crate is deprecated. The code was moved to dusk-poseidon.
Expand description

Implements a Hades252 strategy for BlsScalar as input values.

Implementations§

source§

impl ScalarStrategy

source

pub fn new() -> Self

👎Deprecated: This crate is deprecated. The code was moved to dusk-poseidon.

Constructs a new ScalarStrategy.

Trait Implementations§

source§

impl Default for ScalarStrategy

source§

fn default() -> ScalarStrategy

Returns the “default value” for a type. Read more
source§

impl Strategy<Scalar> for ScalarStrategy

source§

fn add_round_key<'b, I>(&mut self, constants: &mut I, words: &mut [BlsScalar])
where I: Iterator<Item = &'b BlsScalar>,

👎Deprecated: This crate is deprecated. The code was moved to dusk-poseidon.
Add round keys to a set of StrategyInput. Read more
source§

fn quintic_s_box(&mut self, value: &mut BlsScalar)

👎Deprecated: This crate is deprecated. The code was moved to dusk-poseidon.
Computes input ^ 5 (mod Fp) Read more
source§

fn mul_matrix<'b, I>(&mut self, _constants: &mut I, values: &mut [BlsScalar])
where I: Iterator<Item = &'b BlsScalar>,

👎Deprecated: This crate is deprecated. The code was moved to dusk-poseidon.
Multiply the values for MDS matrix during the full rounds application.
source§

fn next_c<'b, I>(constants: &mut I) -> BlsScalar
where I: Iterator<Item = &'b BlsScalar>,

👎Deprecated: This crate is deprecated. The code was moved to dusk-poseidon.
Fetch the next round constant from an iterator
source§

fn apply_partial_round<'b, I>(&mut self, constants: &mut I, words: &mut [T])
where I: Iterator<Item = &'b BlsScalar>,

👎Deprecated: This crate is deprecated. The code was moved to dusk-poseidon.
Applies a Partial Round also known as a Partial S-Box layer to a set of inputs. Read more
source§

fn apply_full_round<'a, I>(&mut self, constants: &mut I, words: &mut [T])
where I: Iterator<Item = &'a BlsScalar>,

👎Deprecated: This crate is deprecated. The code was moved to dusk-poseidon.
Applies a Full Round also known as a Full S-Box layer to a set of inputs. Read more
source§

fn perm(&mut self, data: &mut [T])

👎Deprecated: This crate is deprecated. The code was moved to dusk-poseidon.
Applies a permutation-round of the Hades252 strategy. Read more
source§

fn rounds() -> usize

👎Deprecated: This crate is deprecated. The code was moved to dusk-poseidon.
Return the total rounds count

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.