Struct RecoverableSignature
pub struct RecoverableSignature(/* private fields */);
Expand description
An ECDSA signature with a recovery ID for pubkey recovery.
Implementations§
§impl RecoverableSignature
impl RecoverableSignature
pub fn from_compact(
data: &[u8],
recid: RecoveryId,
) -> Result<RecoverableSignature, Error>
pub fn from_compact( data: &[u8], recid: RecoveryId, ) -> Result<RecoverableSignature, Error>
Converts a compact-encoded byte slice to a signature. This representation is nonstandard and defined by the libsecp256k1 library.
pub fn as_ptr(&self) -> *const RecoverableSignature
pub fn as_ptr(&self) -> *const RecoverableSignature
Obtains a raw pointer suitable for use with FFI functions.
pub fn as_mut_ptr(&mut self) -> *mut RecoverableSignature
pub fn as_mut_ptr(&mut self) -> *mut RecoverableSignature
Obtains a raw mutable pointer suitable for use with FFI functions.
pub fn serialize_compact(&self) -> (RecoveryId, [u8; 64])
pub fn serialize_compact(&self) -> (RecoveryId, [u8; 64])
Serializes the recoverable signature in compact format.
pub fn to_standard(&self) -> Signature
pub fn to_standard(&self) -> Signature
Converts a recoverable signature to a non-recoverable one (this is needed for verification).
Trait Implementations§
§impl CPtr for RecoverableSignature
impl CPtr for RecoverableSignature
type Target = RecoverableSignature
fn as_c_ptr(&self) -> *const <RecoverableSignature as CPtr>::Target
fn as_mut_c_ptr(&mut self) -> *mut <RecoverableSignature as CPtr>::Target
§impl Clone for RecoverableSignature
impl Clone for RecoverableSignature
§fn clone(&self) -> RecoverableSignature
fn clone(&self) -> RecoverableSignature
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read more§impl Debug for RecoverableSignature
impl Debug for RecoverableSignature
§impl From<RecoverableSignature> for RecoverableSignature
impl From<RecoverableSignature> for RecoverableSignature
Creates a new recoverable signature from a FFI one.
§fn from(sig: RecoverableSignature) -> RecoverableSignature
fn from(sig: RecoverableSignature) -> RecoverableSignature
Converts to this type from the input type.
§impl Hash for RecoverableSignature
impl Hash for RecoverableSignature
§impl PartialEq for RecoverableSignature
impl PartialEq for RecoverableSignature
impl Copy for RecoverableSignature
impl Eq for RecoverableSignature
impl StructuralPartialEq for RecoverableSignature
Auto Trait Implementations§
impl Freeze for RecoverableSignature
impl RefUnwindSafe for RecoverableSignature
impl Send for RecoverableSignature
impl Sync for RecoverableSignature
impl Unpin for RecoverableSignature
impl UnwindSafe for RecoverableSignature
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request