pub struct MockTransferFilterContractHostRef { /* private fields */ }Expand description
MockTransferFilterContract Host Ref.
Implementations§
source§impl MockTransferFilterContractHostRef
impl MockTransferFilterContractHostRef
pub fn set_return_value(&mut self, return_value: u8)
pub fn can_transfer(&self) -> u8
source§impl MockTransferFilterContractHostRef
impl MockTransferFilterContractHostRef
sourcepub fn try_set_return_value(&mut self, return_value: u8) -> OdraResult<()>
pub fn try_set_return_value(&mut self, return_value: u8) -> OdraResult<()>
Does not fail in case of error, returns odra::OdraResult instead.
sourcepub fn try_can_transfer(&self) -> OdraResult<u8>
pub fn try_can_transfer(&self) -> OdraResult<u8>
Does not fail in case of error, returns odra::OdraResult instead.
Trait Implementations§
source§impl EntryPointsCallerProvider for MockTransferFilterContractHostRef
impl EntryPointsCallerProvider for MockTransferFilterContractHostRef
source§fn entry_points_caller(env: &HostEnv) -> EntryPointsCaller
fn entry_points_caller(env: &HostEnv) -> EntryPointsCaller
Returns an EntryPointsCaller for the given host environment.
source§impl HostRef for MockTransferFilterContractHostRef
impl HostRef for MockTransferFilterContractHostRef
source§fn new(address: Address, env: HostEnv) -> Self
fn new(address: Address, env: HostEnv) -> Self
Creates a new host side reference to a contract.
source§fn with_tokens(&self, tokens: U512) -> Self
fn with_tokens(&self, tokens: U512) -> Self
Creates a new host reference with attached tokens, based on the current instance. Read more
source§fn get_event<T>(&self, index: i32) -> Result<T, EventError>where
T: FromBytes + EventInstance,
fn get_event<T>(&self, index: i32) -> Result<T, EventError>where
T: FromBytes + EventInstance,
Returns the n-th event emitted by the contract. Read more
source§fn last_call(&self) -> ContractCallResult
fn last_call(&self) -> ContractCallResult
Returns a detailed information about the last call of the contract.
Auto Trait Implementations§
impl Freeze for MockTransferFilterContractHostRef
impl !RefUnwindSafe for MockTransferFilterContractHostRef
impl !Send for MockTransferFilterContractHostRef
impl !Sync for MockTransferFilterContractHostRef
impl Unpin for MockTransferFilterContractHostRef
impl !UnwindSafe for MockTransferFilterContractHostRef
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