Struct pairing::bls12_381::G2
[−]
[src]
pub struct G2 { /* fields omitted */ }
Trait Implementations
impl Copy for G2
[src]
impl Clone for G2
[src]
fn clone(&self) -> G2
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl Debug for G2
[src]
impl Eq for G2
[src]
impl Display for G2
[src]
impl PartialEq for G2
[src]
fn eq(&self, other: &G2) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0
This method tests for !=
.
impl Rand for G2
[src]
fn rand<R: Rng>(rng: &mut R) -> Self
Generates a random instance of this type using the specified source of randomness. Read more
impl CurveProjective for G2
[src]
type Scalar = Fr
type Base = Fq2
type Affine = G2Affine
fn zero() -> Self
Returns the additive identity.
fn one() -> Self
Returns a fixed generator of unknown exponent.
fn is_zero(&self) -> bool
Determines if this point is the point at infinity.
fn is_normalized(&self) -> bool
Checks if the point is already "normalized" so that cheap affine conversion is possible. Read more
fn batch_normalization(v: &mut [Self])
Normalizes a slice of projective elements so that conversion to affine is cheap. Read more
fn double(&mut self)
Doubles this element.
fn add_assign(&mut self, other: &Self)
Adds another element to this element.
fn add_assign_mixed(&mut self, other: &Self::Affine)
Adds an affine element to this element.
fn negate(&mut self)
Negates this element.
fn mul_assign<S: Into<<Self::Scalar as PrimeField>::Repr>>(&mut self, other: S)
Performs scalar multiplication of this element.
fn into_affine(&self) -> G2Affine
Converts this element into its affine representation.
fn recommended_wnaf_for_scalar(
scalar: <Self::Scalar as PrimeField>::Repr
) -> Option<usize>
scalar: <Self::Scalar as PrimeField>::Repr
) -> Option<usize>
Recommends a wNAF window table size given a scalar. Returns None
if normal scalar multiplication is encouraged. If Some
is returned, it will be between 2 and 22, inclusive. Read more
fn recommended_wnaf_for_num_scalars(num_scalars: usize) -> usize
Recommends a wNAF window size given the number of scalars you intend to multiply a base by. Always returns a number between 2 and 22, inclusive. Read more
fn sub_assign(&mut self, other: &Self)
Subtracts another element from this element.