Struct cml_chain_wasm::auxdata::ConwayFormatAuxData
source · pub struct ConwayFormatAuxData(/* private fields */);Implementations§
source§impl ConwayFormatAuxData
impl ConwayFormatAuxData
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 from_cbor_bytes(
cbor_bytes: &[u8]
) -> Result<ConwayFormatAuxData, JsError>
pub fn from_cbor_bytes( cbor_bytes: &[u8] ) -> Result<ConwayFormatAuxData, 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 from_cbor_hex(cbor_bytes: &str) -> Result<ConwayFormatAuxData, JsError>
pub fn from_cbor_hex(cbor_bytes: &str) -> Result<ConwayFormatAuxData, JsError>
- Create this type from the CBOR bytes encoded as a hex string.
- This is useful for interfacing with CIP30
source§impl ConwayFormatAuxData
impl ConwayFormatAuxData
pub fn set_metadata(&mut self, metadata: &Metadata)
pub fn metadata(&self) -> Option<Metadata>
pub fn set_native_scripts(&mut self, native_scripts: &NativeScriptList)
pub fn native_scripts(&self) -> Option<NativeScriptList>
pub fn set_plutus_v1_scripts(&mut self, plutus_v1_scripts: &PlutusV1ScriptList)
pub fn plutus_v1_scripts(&self) -> Option<PlutusV1ScriptList>
pub fn set_plutus_v2_scripts(&mut self, plutus_v2_scripts: &PlutusV2ScriptList)
pub fn plutus_v2_scripts(&self) -> Option<PlutusV2ScriptList>
pub fn set_plutus_v3_scripts(&mut self, plutus_v3_scripts: &PlutusV3ScriptList)
pub fn plutus_v3_scripts(&self) -> Option<PlutusV3ScriptList>
pub fn new() -> Self
Trait Implementations§
source§impl AsRef<ConwayFormatAuxData> for ConwayFormatAuxData
impl AsRef<ConwayFormatAuxData> for ConwayFormatAuxData
source§fn as_ref(&self) -> &ConwayFormatAuxData
fn as_ref(&self) -> &ConwayFormatAuxData
Converts this type into a shared reference of the (usually inferred) input type.
source§impl Clone for ConwayFormatAuxData
impl Clone for ConwayFormatAuxData
source§fn clone(&self) -> ConwayFormatAuxData
fn clone(&self) -> ConwayFormatAuxData
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 ConwayFormatAuxData
impl Debug for ConwayFormatAuxData
source§impl From<ConwayFormatAuxData> for ConwayFormatAuxData
impl From<ConwayFormatAuxData> for ConwayFormatAuxData
source§fn from(native: ConwayFormatAuxData) -> Self
fn from(native: ConwayFormatAuxData) -> Self
Converts to this type from the input type.
source§impl From<ConwayFormatAuxData> for JsValue
impl From<ConwayFormatAuxData> for JsValue
source§fn from(value: ConwayFormatAuxData) -> Self
fn from(value: ConwayFormatAuxData) -> Self
Converts to this type from the input type.
source§impl FromWasmAbi for ConwayFormatAuxData
impl FromWasmAbi for ConwayFormatAuxData
source§impl Into<ConwayFormatAuxData> for ConwayFormatAuxData
impl Into<ConwayFormatAuxData> for ConwayFormatAuxData
source§fn into(self) -> ConwayFormatAuxData
fn into(self) -> ConwayFormatAuxData
Converts this type into the (usually inferred) input type.
source§impl IntoWasmAbi for ConwayFormatAuxData
impl IntoWasmAbi for ConwayFormatAuxData
source§impl RefFromWasmAbi for ConwayFormatAuxData
impl RefFromWasmAbi for ConwayFormatAuxData
§type Anchor = Ref<'static, ConwayFormatAuxData>
type Anchor = Ref<'static, ConwayFormatAuxData>
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.Auto Trait Implementations§
impl Freeze for ConwayFormatAuxData
impl RefUnwindSafe for ConwayFormatAuxData
impl Send for ConwayFormatAuxData
impl Sync for ConwayFormatAuxData
impl Unpin for ConwayFormatAuxData
impl UnwindSafe for ConwayFormatAuxData
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> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
§type Abi = <T as IntoWasmAbi>::Abi
type Abi = <T as IntoWasmAbi>::Abi
Same as
IntoWasmAbi::Abisource§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.