FungibleAsset

Trait FungibleAsset 

Source
pub trait FungibleAsset: Clone + Asset {
    // Required methods
    fn make_child(&self, p2_puzzle_hash: Bytes32, amount: u64) -> Self;
    fn child_memos(
        &self,
        ctx: &mut SpendContext,
        p2_puzzle_hash: Bytes32,
    ) -> Result<Memos, DriverError>;
}

Required Methods§

Source

fn make_child(&self, p2_puzzle_hash: Bytes32, amount: u64) -> Self

Source

fn child_memos( &self, ctx: &mut SpendContext, p2_puzzle_hash: Bytes32, ) -> Result<Memos, DriverError>

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl FungibleAsset for Coin

Source§

fn make_child(&self, p2_puzzle_hash: Bytes32, amount: u64) -> Self

Source§

fn child_memos( &self, _ctx: &mut SpendContext, _p2_puzzle_hash: Bytes32, ) -> Result<Memos, DriverError>

Implementors§