Struct curve25519_dalek::edwards::CompressedEdwardsY [−][src]
In “Edwards y” / “Ed25519” format, the curve point \((x,y)\) is determined by the \(y\)-coordinate and the sign of \(x\).
The first 255 bits of a CompressedEdwardsY represent the
\(y\)-coordinate. The high bit of the 32nd byte gives the sign of \(x\).
Implementations
impl CompressedEdwardsY[src]
impl CompressedEdwardsY[src]pub fn as_bytes(&self) -> &[u8; 32][src]
View this CompressedEdwardsY as an array of bytes.
pub fn to_bytes(&self) -> [u8; 32][src]
Copy this CompressedEdwardsY to an array of bytes.
pub fn decompress(&self) -> Option<EdwardsPoint>[src]
Attempt to decompress to an EdwardsPoint.
Returns None if the input is not the \(y\)-coordinate of a
curve point.
impl CompressedEdwardsY[src]
impl CompressedEdwardsY[src]pub fn from_slice(bytes: &[u8]) -> CompressedEdwardsY[src]
Construct a CompressedEdwardsY from a slice of bytes.
Panics
If the input bytes slice does not have a length of 32.
Trait Implementations
impl Clone for CompressedEdwardsY[src]
impl Clone for CompressedEdwardsY[src]fn clone(&self) -> CompressedEdwardsY[src]
pub fn clone_from(&mut self, source: &Self)1.0.0[src]
impl ConstantTimeEq for CompressedEdwardsY[src]
impl ConstantTimeEq for CompressedEdwardsY[src]fn ct_eq(&self, other: &CompressedEdwardsY) -> Choice[src]
impl Default for CompressedEdwardsY[src]
impl Default for CompressedEdwardsY[src]fn default() -> CompressedEdwardsY[src]
impl Hash for CompressedEdwardsY[src]
impl Hash for CompressedEdwardsY[src]impl Identity for CompressedEdwardsY[src]
impl Identity for CompressedEdwardsY[src]fn identity() -> CompressedEdwardsY[src]
impl PartialEq<CompressedEdwardsY> for CompressedEdwardsY[src]
impl PartialEq<CompressedEdwardsY> for CompressedEdwardsY[src]fn eq(&self, other: &CompressedEdwardsY) -> bool[src]
fn ne(&self, other: &CompressedEdwardsY) -> bool[src]
impl Copy for CompressedEdwardsY[src]
impl Eq for CompressedEdwardsY[src]
impl StructuralEq for CompressedEdwardsY[src]
impl StructuralPartialEq for CompressedEdwardsY[src]
Auto Trait Implementations
impl RefUnwindSafe for CompressedEdwardsY
impl Send for CompressedEdwardsY
impl Sync for CompressedEdwardsY
impl Unpin for CompressedEdwardsY
impl UnwindSafe for CompressedEdwardsY
Blanket Implementations
impl<T> IsIdentity for T where
T: ConstantTimeEq + Identity, [src]
impl<T> IsIdentity for T where
T: ConstantTimeEq + Identity, [src]