pub struct Point<E: JubjubEngine, Subgroup> { /* private fields */ }
Implementations§
Source§impl<E: JubjubEngine> Point<E, Unknown>
impl<E: JubjubEngine> Point<E, Unknown>
Source§impl<E: JubjubEngine, Subgroup> Point<E, Subgroup>
impl<E: JubjubEngine, Subgroup> Point<E, Subgroup>
Sourcepub fn from_edwards(e: &Point<E, Subgroup>, params: &E::Params) -> Self
pub fn from_edwards(e: &Point<E, Subgroup>, params: &E::Params) -> Self
Convert from an Edwards point
Sourcepub fn as_prime_order(&self, params: &E::Params) -> Option<Point<E, PrimeOrder>>
pub fn as_prime_order(&self, params: &E::Params) -> Option<Point<E, PrimeOrder>>
Attempts to cast this as a prime order element, failing if it’s not in the prime order subgroup.
pub fn zero() -> Self
pub fn into_xy(&self) -> Option<(E::Fr, E::Fr)>
pub fn negate(&self) -> Self
pub fn double(&self, params: &E::Params) -> Self
pub fn add(&self, other: &Self, params: &E::Params) -> Self
pub fn mul<S: Into<<E::Fs as PrimeField>::Repr>>( &self, scalar: S, params: &E::Params, ) -> Self
Trait Implementations§
Source§impl<E: JubjubEngine, Subgroup> Clone for Point<E, Subgroup>
impl<E: JubjubEngine, Subgroup> Clone for Point<E, Subgroup>
Source§impl<E: JubjubEngine> From<Point<E, PrimeOrder>> for Point<E, Unknown>
impl<E: JubjubEngine> From<Point<E, PrimeOrder>> for Point<E, Unknown>
Source§impl<E: JubjubEngine, Subgroup> PartialEq for Point<E, Subgroup>
impl<E: JubjubEngine, Subgroup> PartialEq for Point<E, Subgroup>
Auto Trait Implementations§
impl<E, Subgroup> Freeze for Point<E, Subgroup>
impl<E, Subgroup> RefUnwindSafe for Point<E, Subgroup>
impl<E, Subgroup> Send for Point<E, Subgroup>where
Subgroup: Send,
impl<E, Subgroup> Sync for Point<E, Subgroup>where
Subgroup: Sync,
impl<E, Subgroup> Unpin for Point<E, Subgroup>
impl<E, Subgroup> UnwindSafe for Point<E, Subgroup>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more