pub struct Bn<P: BnParameters>(_);
Trait Implementations
sourceimpl<P: BnParameters> Clone for Bn<P>
impl<P: BnParameters> Clone for Bn<P>
sourceimpl<P: BnParameters> Debug for Bn<P>
impl<P: BnParameters> Debug for Bn<P>
sourceimpl<P: BnParameters> Hash for Bn<P>
impl<P: BnParameters> Hash for Bn<P>
sourceimpl<P: BnParameters> Pairing for Bn<P>
impl<P: BnParameters> Pairing for Bn<P>
type ScalarField = <<P as BnParameters>::G1Parameters as CurveConfig>::ScalarField
type ScalarField = <<P as BnParameters>::G1Parameters as CurveConfig>::ScalarField
This is the scalar field of the G1/G2 groups.
type G1 = Projective<<P as BnParameters>::G1Parameters>
type G1 = Projective<<P as BnParameters>::G1Parameters>
An element in G1.
type G1Affine = Affine<<P as BnParameters>::G1Parameters>
type G1Prepared = G1Prepared<P>
type G1Prepared = G1Prepared<P>
A G1 element that has been preprocessed for use in a pairing.
type G2 = Projective<<P as BnParameters>::G2Parameters>
type G2 = Projective<<P as BnParameters>::G2Parameters>
An element of G2.
type G2Affine = Affine<<P as BnParameters>::G2Parameters>
type G2Affine = Affine<<P as BnParameters>::G2Parameters>
The affine representation of an element in G2.
type G2Prepared = G2Prepared<P>
type G2Prepared = G2Prepared<P>
A G2 element that has been preprocessed for use in a pairing.
type TargetField = QuadExtField<Fp12ConfigWrapper<<P as BnParameters>::Fp12Config>>
type TargetField = QuadExtField<Fp12ConfigWrapper<<P as BnParameters>::Fp12Config>>
The extension field that hosts the target group of the pairing.
sourcefn multi_miller_loop(
a: impl IntoIterator<Item = impl Into<Self::G1Prepared>>,
b: impl IntoIterator<Item = impl Into<Self::G2Prepared>>
) -> MillerLoopOutput<Self>
fn multi_miller_loop(
a: impl IntoIterator<Item = impl Into<Self::G1Prepared>>,
b: impl IntoIterator<Item = impl Into<Self::G2Prepared>>
) -> MillerLoopOutput<Self>
Computes the product of Miller loops for some number of (G1, G2) pairs.
sourcefn final_exponentiation(
f: MillerLoopOutput<Self>
) -> Option<PairingOutput<Self>>
fn final_exponentiation(
f: MillerLoopOutput<Self>
) -> Option<PairingOutput<Self>>
Performs final exponentiation of the result of a
Self::multi_miller_loop
.sourcefn miller_loop(
a: impl Into<Self::G1Prepared>,
b: impl Into<Self::G2Prepared>
) -> MillerLoopOutput<Self>
fn miller_loop(
a: impl Into<Self::G1Prepared>,
b: impl Into<Self::G2Prepared>
) -> MillerLoopOutput<Self>
Computes the Miller loop over
a
and b
.sourcefn multi_pairing(
a: impl IntoIterator<Item = impl Into<Self::G1Prepared>>,
b: impl IntoIterator<Item = impl Into<Self::G2Prepared>>
) -> PairingOutput<Self>
fn multi_pairing(
a: impl IntoIterator<Item = impl Into<Self::G1Prepared>>,
b: impl IntoIterator<Item = impl Into<Self::G2Prepared>>
) -> PairingOutput<Self>
Computes a “product” of pairings.
sourcefn pairing(
p: impl Into<Self::G1Prepared>,
q: impl Into<Self::G2Prepared>
) -> PairingOutput<Self>
fn pairing(
p: impl Into<Self::G1Prepared>,
q: impl Into<Self::G2Prepared>
) -> PairingOutput<Self>
Performs multiple pairing operations
impl<P: BnParameters> Copy for Bn<P>
impl<P: BnParameters> Eq for Bn<P>
Auto Trait Implementations
impl<P> RefUnwindSafe for Bn<P>
impl<P> Send for Bn<P>
impl<P> Sync for Bn<P>
impl<P> Unpin for Bn<P>
impl<P> UnwindSafe for Bn<P>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more