[][src]Struct ckb_multisig::secp256k1::Signature

pub struct Signature(_);

TODO(doc): @zhangsoledad

Implementations

impl Signature[src]

pub fn r(&self) -> &[u8][src]

Get a slice into the 'r' portion of the data.

pub fn s(&self) -> &[u8][src]

Get a slice into the 's' portion of the data.

pub fn v(&self) -> u8[src]

Get the recovery id.

pub fn from_compact(rec_id: RecoveryId, ret: [u8; 64]) -> Signature[src]

TODO(doc): @zhangsoledad

pub fn from_rsv(r: &H256, s: &H256, v: u8) -> Signature[src]

Create a signature object from the sig.

pub fn from_slice(data: &[u8]) -> Result<Signature, Error>[src]

TODO(doc): @zhangsoledad

pub fn is_valid(&self) -> bool[src]

Check if each component of the signature is in range.

pub fn to_recoverable(&self) -> Result<RecoverableSignature, Error>[src]

Converts compact signature to a recoverable signature

pub fn recover(&self, message: &H256) -> Result<Pubkey, Error>[src]

Determines the public key for signature

pub fn serialize(&self) -> Vec<u8>[src]

TODO(doc): @zhangsoledad

pub fn serialize_der(&self) -> Vec<u8>[src]

TODO(doc): @zhangsoledad

Trait Implementations

impl Clone for Signature[src]

impl Debug for Signature[src]

impl From<H520> for Signature[src]

impl From<Vec<u8>> for Signature[src]

impl FromStr for Signature[src]

type Err = Error

The associated error which can be returned from parsing.

Auto Trait Implementations

Blanket Implementations

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

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

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

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

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

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

type Owned = T

The resulting type after obtaining ownership.

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.

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.