Struct libsecp256k1::SecretKey
source · pub struct SecretKey(_);
Expand description
Secret key (256-bit) on a secp256k1 curve.
Implementations§
source§impl SecretKey
impl SecretKey
pub fn parse(p: &[u8; 32]) -> Result<SecretKey, Error>
pub fn parse_slice(p: &[u8]) -> Result<SecretKey, Error>
pub fn random<R: Rng>(rng: &mut R) -> SecretKey
pub fn serialize(&self) -> [u8; 32]
pub fn tweak_add_assign(&mut self, tweak: &SecretKey) -> Result<(), Error>
pub fn tweak_mul_assign(&mut self, tweak: &SecretKey) -> Result<(), Error>
pub fn inv(&self) -> Self
Trait Implementations§
source§impl PartialEq<SecretKey> for SecretKey
impl PartialEq<SecretKey> for SecretKey
impl Copy for SecretKey
impl Eq for SecretKey
impl StructuralEq for SecretKey
impl StructuralPartialEq for SecretKey
Auto Trait Implementations§
impl RefUnwindSafe for SecretKey
impl Send for SecretKey
impl Sync for SecretKey
impl Unpin for SecretKey
impl UnwindSafe for SecretKey
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