pub struct BootstrapWitness(/* private fields */);
Implementations§
Source§impl BootstrapWitness
impl BootstrapWitness
pub fn to_address(&self) -> Result<AddressContent, JsError>
Source§impl BootstrapWitness
impl BootstrapWitness
Sourcepub fn to_cbor_bytes(&self) -> Vec<u8> ⓘ
pub fn to_cbor_bytes(&self) -> Vec<u8> ⓘ
- Serialize this type to CBOR bytes
- This type type supports encoding preservation so this will preserve round-trip CBOR formats.
- If created from scratch the CBOR will be canonical.
Sourcepub fn to_canonical_cbor_bytes(&self) -> Vec<u8> ⓘ
pub fn to_canonical_cbor_bytes(&self) -> Vec<u8> ⓘ
- Serialize this type to CBOR bytes using canonical CBOR encodings
Sourcepub fn from_cbor_bytes(cbor_bytes: &[u8]) -> Result<BootstrapWitness, JsError>
pub fn from_cbor_bytes(cbor_bytes: &[u8]) -> Result<BootstrapWitness, JsError>
- Create this type from CBOR bytes
Sourcepub fn to_cbor_hex(&self) -> String
pub fn to_cbor_hex(&self) -> String
- Serialize this type to CBOR bytes encoded as a hex string (useful for working with CIP30).
- This type type supports encoding preservation so this will preserve round-trip CBOR formats.
- If created from scratch the CBOR will be canonical.
Sourcepub fn to_canonical_cbor_hex(&self) -> String
pub fn to_canonical_cbor_hex(&self) -> String
- Serialize this type to CBOR bytes using canonical CBOR encodings as hex bytes
Sourcepub fn from_cbor_hex(cbor_bytes: &str) -> Result<BootstrapWitness, JsError>
pub fn from_cbor_hex(cbor_bytes: &str) -> Result<BootstrapWitness, JsError>
- Create this type from the CBOR bytes encoded as a hex string.
- This is useful for interfacing with CIP30
Source§impl BootstrapWitness
impl BootstrapWitness
pub fn public_key(&self) -> Vkey
pub fn signature(&self) -> Ed25519Signature
pub fn chain_code(&self) -> Vec<u8> ⓘ
pub fn attributes(&self) -> AddrAttributes
pub fn new( public_key: &Vkey, signature: &Ed25519Signature, chain_code: Vec<u8>, attributes: &AddrAttributes, ) -> Result<BootstrapWitness, JsError>
Trait Implementations§
Source§impl AsRef<BootstrapWitness> for BootstrapWitness
impl AsRef<BootstrapWitness> for BootstrapWitness
Source§fn as_ref(&self) -> &BootstrapWitness
fn as_ref(&self) -> &BootstrapWitness
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl Clone for BootstrapWitness
impl Clone for BootstrapWitness
Source§fn clone(&self) -> BootstrapWitness
fn clone(&self) -> BootstrapWitness
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 moreSource§impl Debug for BootstrapWitness
impl Debug for BootstrapWitness
Source§impl From<BootstrapWitness> for BootstrapWitness
impl From<BootstrapWitness> for BootstrapWitness
Source§fn from(native: BootstrapWitness) -> Self
fn from(native: BootstrapWitness) -> Self
Converts to this type from the input type.
Source§impl From<BootstrapWitness> for JsValue
impl From<BootstrapWitness> for JsValue
Source§fn from(value: BootstrapWitness) -> Self
fn from(value: BootstrapWitness) -> Self
Converts to this type from the input type.
Source§impl FromWasmAbi for BootstrapWitness
impl FromWasmAbi for BootstrapWitness
Source§impl Into<BootstrapWitness> for BootstrapWitness
impl Into<BootstrapWitness> for BootstrapWitness
Source§fn into(self) -> BootstrapWitness
fn into(self) -> BootstrapWitness
Converts this type into the (usually inferred) input type.
Source§impl IntoWasmAbi for BootstrapWitness
impl IntoWasmAbi for BootstrapWitness
Source§impl OptionFromWasmAbi for BootstrapWitness
impl OptionFromWasmAbi for BootstrapWitness
Source§impl OptionIntoWasmAbi for BootstrapWitness
impl OptionIntoWasmAbi for BootstrapWitness
Source§impl RefFromWasmAbi for BootstrapWitness
impl RefFromWasmAbi for BootstrapWitness
Source§type Anchor = RcRef<BootstrapWitness>
type Anchor = RcRef<BootstrapWitness>
The type that holds the reference to
Self
for the duration of the
invocation of the function that has an &Self
parameter. This is
required to ensure that the lifetimes don’t persist beyond one function
call, and so that they remain anonymous.Source§impl RefMutFromWasmAbi for BootstrapWitness
impl RefMutFromWasmAbi for BootstrapWitness
Source§impl TryFromJsValue for BootstrapWitness
impl TryFromJsValue for BootstrapWitness
Source§impl VectorFromWasmAbi for BootstrapWitness
impl VectorFromWasmAbi for BootstrapWitness
type Abi = <Box<[JsValue]> as FromWasmAbi>::Abi
unsafe fn vector_from_abi(js: Self::Abi) -> Box<[BootstrapWitness]>
Source§impl VectorIntoJsValue for BootstrapWitness
impl VectorIntoJsValue for BootstrapWitness
fn vector_into_jsvalue(vector: Box<[BootstrapWitness]>) -> JsValue
Source§impl VectorIntoWasmAbi for BootstrapWitness
impl VectorIntoWasmAbi for BootstrapWitness
type Abi = <Box<[JsValue]> as IntoWasmAbi>::Abi
fn vector_into_abi(vector: Box<[BootstrapWitness]>) -> Self::Abi
Source§impl WasmDescribeVector for BootstrapWitness
impl WasmDescribeVector for BootstrapWitness
impl SupportsConstructor for BootstrapWitness
impl SupportsInstanceProperty for BootstrapWitness
impl SupportsStaticProperty for BootstrapWitness
Auto Trait Implementations§
impl Freeze for BootstrapWitness
impl RefUnwindSafe for BootstrapWitness
impl Send for BootstrapWitness
impl Sync for BootstrapWitness
impl Unpin for BootstrapWitness
impl UnwindSafe for BootstrapWitness
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
Source§type Abi = <T as IntoWasmAbi>::Abi
type Abi = <T as IntoWasmAbi>::Abi
Same as
IntoWasmAbi::Abi
Source§fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
Same as
IntoWasmAbi::into_abi
, except that it may throw and never
return in the case of Err
.