Trait multiversx_sc::api::CallValueApiImpl
source · pub trait CallValueApiImpl: ErrorApiImpl + ManagedTypeApiImpl + Sized {
// Required methods
fn check_not_payable(&self);
fn load_egld_value(&self, dest_handle: Self::BigIntHandle);
fn load_all_esdt_transfers(&self, dest_handle: Self::ManagedBufferHandle);
fn esdt_num_transfers(&self) -> usize;
}
Required Methods§
fn check_not_payable(&self)
sourcefn load_egld_value(&self, dest_handle: Self::BigIntHandle)
fn load_egld_value(&self, dest_handle: Self::BigIntHandle)
Retrieves the EGLD call value from the VM. Will return 0 in case of an ESDT transfer (cannot have both EGLD and ESDT transfer simultaneously).
sourcefn load_all_esdt_transfers(&self, dest_handle: Self::ManagedBufferHandle)
fn load_all_esdt_transfers(&self, dest_handle: Self::ManagedBufferHandle)
Loads all ESDT call values into a managed vec. Overwrites destination.
sourcefn esdt_num_transfers(&self) -> usize
fn esdt_num_transfers(&self) -> usize
Gets the total number of ESDT transfers (Fungible/SFT/NFT).
It is redundant, since the number can also be retrieved from load_all_esdt_transfers
,
but it is easier and cheaper to call when the content of those transfers is of no interest.