pub struct BigNumContext(/* private fields */);
Expand description
Temporary storage for BigNums on the secure heap
BigNum values are stored dynamically and therefore can be expensive
to allocate. BigNumContext and the OpenSSL BN_CTX
structure are used
internally when passing BigNum values between subroutines.
Implementations§
source§impl BigNumContext
impl BigNumContext
sourcepub fn new() -> Result<BigNumContext, ErrorStack>
pub fn new() -> Result<BigNumContext, ErrorStack>
Returns a new BigNumContext
.
This corresponds to BN_CTX_new
.
sourcepub fn new_secure() -> Result<BigNumContext, ErrorStack>
pub fn new_secure() -> Result<BigNumContext, ErrorStack>
Returns a new secure BigNumContext
.
This corresponds to BN_CTX_secure_new
.
Trait Implementations§
source§impl AsRef<BigNumContextRef> for BigNumContext
impl AsRef<BigNumContextRef> for BigNumContext
source§fn as_ref(&self) -> &BigNumContextRef
fn as_ref(&self) -> &BigNumContextRef
Converts this type into a shared reference of the (usually inferred) input type.
source§impl Borrow<BigNumContextRef> for BigNumContext
impl Borrow<BigNumContextRef> for BigNumContext
source§fn borrow(&self) -> &BigNumContextRef
fn borrow(&self) -> &BigNumContextRef
Immutably borrows from an owned value. Read more
source§impl Deref for BigNumContext
impl Deref for BigNumContext
source§type Target = BigNumContextRef
type Target = BigNumContextRef
The resulting type after dereferencing.
source§fn deref(&self) -> &BigNumContextRef
fn deref(&self) -> &BigNumContextRef
Dereferences the value.
source§impl DerefMut for BigNumContext
impl DerefMut for BigNumContext
source§fn deref_mut(&mut self) -> &mut BigNumContextRef
fn deref_mut(&mut self) -> &mut BigNumContextRef
Mutably dereferences the value.
source§impl Drop for BigNumContext
impl Drop for BigNumContext
source§impl ForeignType for BigNumContext
impl ForeignType for BigNumContext
source§type Ref = BigNumContextRef
type Ref = BigNumContextRef
The type representing a reference to this type.
impl Send for BigNumContext
impl Sync for BigNumContext
Auto Trait Implementations§
impl Freeze for BigNumContext
impl RefUnwindSafe for BigNumContext
impl Unpin for BigNumContext
impl UnwindSafe for BigNumContext
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