Struct dharitri_wasm::types::DctTokenData
source · pub struct DctTokenData<BigUint: BigUintApi> {
pub token_type: DctTokenType,
pub amount: BigUint,
pub frozen: bool,
pub hash: H256,
pub name: BoxedBytes,
pub attributes: BoxedBytes,
pub creator: Address,
pub royalties: BigUint,
pub uris: Vec<BoxedBytes>,
}Fields§
§token_type: DctTokenType§amount: BigUint§frozen: bool§hash: H256§name: BoxedBytes§attributes: BoxedBytes§creator: Address§royalties: BigUint§uris: Vec<BoxedBytes>Implementations§
source§impl<BigUint: BigUintApi> DctTokenData<BigUint>
impl<BigUint: BigUintApi> DctTokenData<BigUint>
pub fn decode_attributes<T: TopDecode>(&self) -> Result<T, DecodeError>
Trait Implementations§
source§impl<BigUint: BigUintApi> NestedDecode for DctTokenData<BigUint>
impl<BigUint: BigUintApi> NestedDecode for DctTokenData<BigUint>
source§fn dep_decode<I: NestedDecodeInput>(input: &mut I) -> Result<Self, DecodeError>
fn dep_decode<I: NestedDecodeInput>(input: &mut I) -> Result<Self, DecodeError>
Attempt to deserialise the value from input,
using the format of an object nested inside another structure.
In case of success returns the deserialized value and the number of bytes consumed during the operation.
source§fn dep_decode_or_exit<I: NestedDecodeInput, ExitCtx: Clone>(
input: &mut I,
c: ExitCtx,
exit: fn(_: ExitCtx, _: DecodeError) -> !
) -> Self
fn dep_decode_or_exit<I: NestedDecodeInput, ExitCtx: Clone>( input: &mut I, c: ExitCtx, exit: fn(_: ExitCtx, _: DecodeError) -> ! ) -> Self
Version of
top_decode that exits quickly in case of error.
Its purpose is to create smaller implementations
in cases where the application is supposed to exit directly on decode error.source§impl<BigUint: BigUintApi> NestedEncode for DctTokenData<BigUint>
impl<BigUint: BigUintApi> NestedEncode for DctTokenData<BigUint>
source§fn dep_encode<O: NestedEncodeOutput>(
&self,
dest: &mut O
) -> Result<(), EncodeError>
fn dep_encode<O: NestedEncodeOutput>( &self, dest: &mut O ) -> Result<(), EncodeError>
NestedEncode to output, using the format of an object nested inside another structure.
Does not provide compact version.
source§fn dep_encode_or_exit<O: NestedEncodeOutput, ExitCtx: Clone>(
&self,
dest: &mut O,
c: ExitCtx,
exit: fn(_: ExitCtx, _: EncodeError) -> !
)
fn dep_encode_or_exit<O: NestedEncodeOutput, ExitCtx: Clone>( &self, dest: &mut O, c: ExitCtx, exit: fn(_: ExitCtx, _: EncodeError) -> ! )
Version of
top_decode that exits quickly in case of error.
Its purpose is to create smaller implementations
in cases where the application is supposed to exit directly on decode error.source§impl<BigUint: BigUintApi> TopDecode for DctTokenData<BigUint>
impl<BigUint: BigUintApi> TopDecode for DctTokenData<BigUint>
source§fn top_decode<I: TopDecodeInput>(input: I) -> Result<Self, DecodeError>
fn top_decode<I: TopDecodeInput>(input: I) -> Result<Self, DecodeError>
Attempt to deserialize the value from input.
source§fn top_decode_or_exit<I: TopDecodeInput, ExitCtx: Clone>(
input: I,
c: ExitCtx,
exit: fn(_: ExitCtx, _: DecodeError) -> !
) -> Self
fn top_decode_or_exit<I: TopDecodeInput, ExitCtx: Clone>( input: I, c: ExitCtx, exit: fn(_: ExitCtx, _: DecodeError) -> ! ) -> Self
Version of
top_decode that exits quickly in case of error.
Its purpose is to create smaller implementations
in cases where the application is supposed to exit directly on decode error.source§impl<BigUint: BigUintApi> TopEncode for DctTokenData<BigUint>
impl<BigUint: BigUintApi> TopEncode for DctTokenData<BigUint>
source§fn top_encode<O: TopEncodeOutput>(&self, output: O) -> Result<(), EncodeError>
fn top_encode<O: TopEncodeOutput>(&self, output: O) -> Result<(), EncodeError>
Attempt to serialize the value to ouput.
source§fn top_encode_or_exit<O: TopEncodeOutput, ExitCtx: Clone>(
&self,
output: O,
c: ExitCtx,
exit: fn(_: ExitCtx, _: EncodeError) -> !
)
fn top_encode_or_exit<O: TopEncodeOutput, ExitCtx: Clone>( &self, output: O, c: ExitCtx, exit: fn(_: ExitCtx, _: EncodeError) -> ! )
Version of
top_decode that exits quickly in case of error.
Its purpose is to create smaller bytecode implementations
in cases where the application is supposed to exit directly on decode error.source§impl<BigUint: BigUintApi> TypeAbi for DctTokenData<BigUint>
impl<BigUint: BigUintApi> TypeAbi for DctTokenData<BigUint>
fn type_name() -> String
source§fn provide_type_descriptions<TDC: TypeDescriptionContainer>(
accumulator: &mut TDC
)
fn provide_type_descriptions<TDC: TypeDescriptionContainer>( accumulator: &mut TDC )
A type can provide more than its own description.
For instance, a struct can also provide the descriptions of the type of its fields.
TypeAbi doesn’t care for the exact accumulator type,
which is abstracted by the TypeDescriptionContainer trait.
Auto Trait Implementations§
impl<BigUint> RefUnwindSafe for DctTokenData<BigUint>where
BigUint: RefUnwindSafe,
impl<BigUint> Send for DctTokenData<BigUint>where
BigUint: Send,
impl<BigUint> Sync for DctTokenData<BigUint>where
BigUint: Sync,
impl<BigUint> Unpin for DctTokenData<BigUint>where
BigUint: Unpin,
impl<BigUint> UnwindSafe for DctTokenData<BigUint>where
BigUint: UnwindSafe,
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