Struct pairing_ce::EncodingBytes[][src]

pub struct EncodingBytes<G: GenericCurveAffine, const N: usize> { /* fields omitted */ }

Implementations

impl<G: GenericCurveAffine, const N: usize> EncodingBytes<G, N>[src]

pub fn empty() -> Self[src]

Creates an empty representation.

pub fn size() -> usize[src]

Returns the number of bytes consumed by this representation.

pub fn into_bytes(self) -> [u8; N][src]

Transforms into raw bytes without a type marker

pub fn from_bytes(bytes: [u8; N]) -> Self[src]

Transforms from raw bytes by adding a type marker

Trait Implementations

impl<G: GenericCurveAffine, const N: usize> AsMut<[u8]> for EncodingBytes<G, N>[src]

fn as_mut(&mut self) -> &mut [u8][src]

Performs the conversion.

impl<G: GenericCurveAffine, const N: usize> AsRef<[u8]> for EncodingBytes<G, N>[src]

fn as_ref(&self) -> &[u8][src]

Performs the conversion.

impl<G: Clone + GenericCurveAffine, const N: usize> Clone for EncodingBytes<G, N>[src]

fn clone(&self) -> EncodingBytes<G, N>[src]

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl<G: Debug + GenericCurveAffine, const N: usize> Debug for EncodingBytes<G, N>[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl<G: Hash + GenericCurveAffine, const N: usize> Hash for EncodingBytes<G, N>[src]

fn hash<__H: Hasher>(&self, state: &mut __H)[src]

Feeds this value into the given Hasher. Read more

fn hash_slice<H>(data: &[Self], state: &mut H) where
    H: Hasher
1.3.0[src]

Feeds a slice of this type into the given Hasher. Read more

impl<G: PartialEq + GenericCurveAffine, const N: usize> PartialEq<EncodingBytes<G, N>> for EncodingBytes<G, N>[src]

fn eq(&self, other: &EncodingBytes<G, N>) -> bool[src]

This method tests for self and other values to be equal, and is used by ==. Read more

fn ne(&self, other: &EncodingBytes<G, N>) -> bool[src]

This method tests for !=.

impl<G: Copy + GenericCurveAffine, const N: usize> Copy for EncodingBytes<G, N>[src]

impl<G: Eq + GenericCurveAffine, const N: usize> Eq for EncodingBytes<G, N>[src]

impl<G: GenericCurveAffine, const N: usize> StructuralEq for EncodingBytes<G, N>[src]

impl<G: GenericCurveAffine, const N: usize> StructuralPartialEq for EncodingBytes<G, N>[src]

Auto Trait Implementations

impl<G, const N: usize> RefUnwindSafe for EncodingBytes<G, N> where
    G: RefUnwindSafe

impl<G, const N: usize> Send for EncodingBytes<G, N>

impl<G, const N: usize> Sync for EncodingBytes<G, N>

impl<G, const N: usize> Unpin for EncodingBytes<G, N> where
    G: Unpin

impl<G, const N: usize> UnwindSafe for EncodingBytes<G, N> where
    G: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<T> ToHex for T where
    T: AsRef<[u8]>, 
[src]

pub fn encode_hex<U>(&self) -> U where
    U: FromIterator<char>, 
[src]

Encode the hex strict representing self into the result. Lower case letters are used (e.g. f9b4ca) Read more

pub fn encode_hex_upper<U>(&self) -> U where
    U: FromIterator<char>, 
[src]

Encode the hex strict representing self into the result. Upper case letters are used (e.g. F9B4CA) Read more

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

pub fn to_owned(&self) -> T[src]

Creates owned data from borrowed data, usually by cloning. Read more

pub fn clone_into(&self, target: &mut T)[src]

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

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

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

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

Performs the conversion.