pub struct ContractObj<A>
where A: VMApi + Clone + 'static,
{ /* private fields */ }

Trait Implementations§

source§

impl<A> CallableContract<A> for ContractObj<A>
where A: VMApi + Clone + 'static,

source§

fn call(&self, fn_name: &[u8]) -> bool

source§

fn into_api(self: Box<Self>) -> A

source§

impl<A> ContractBase for ContractObj<A>
where A: VMApi + Clone + 'static,

§

type Api = A

source§

fn raw_vm_api(&self) -> Self::Api

Grants direct access to the underlying VM API. Avoid using it directly.
source§

fn call_value(&self) -> CallValueWrapper<Self::Api>

Gateway into the call value retrieval functionality. The payment annotations should normally be the ones to handle this, but the developer is also given direct access to the API.
source§

fn send(&self) -> SendWrapper<Self::Api>

Gateway to the functionality related to sending transactions from the current contract.
source§

fn type_manager(&self) -> Self::Api

Managed types API. Required to create new instances of managed types.
source§

fn types(&self) -> ManagedTypeHelper<Self::Api>

Helps create new instances of managed types
source§

fn blockchain(&self) -> BlockchainWrapper<Self::Api>

Gateway blockchain info related to the current transaction and to accounts.
source§

fn crypto(&self) -> CryptoWrapper<Self::Api>

Stateless crypto functions provided by the Arwen VM.
source§

fn serializer(&self) -> ManagedSerializer<Self::Api>

Component that provides contract developers access to highly optimized manual serialization and deserialization.
source§

fn error(&self) -> ErrorHelper<Self::Api>

source§

impl<A> EndpointWrappers for ContractObj<A>
where A: VMApi + Clone + 'static,

source§

fn call_set_feature_flag_endpoint(&self)

source§

fn call(&self, fn_name: &[u8]) -> bool

source§

fn callback_selector( &self, ___cb_closure___: CallbackClosureForDeser<Self::Api> ) -> CallbackSelectorResult<Self::Api>

source§

fn callback(&self)

source§

impl<A> AutoImpl for ContractObj<A>
where A: VMApi + Clone + 'static,

Auto Trait Implementations§

§

impl<A> RefUnwindSafe for ContractObj<A>
where A: RefUnwindSafe,

§

impl<A> Send for ContractObj<A>
where A: Send,

§

impl<A> Sync for ContractObj<A>
where A: Sync,

§

impl<A> Unpin for ContractObj<A>
where A: Unpin,

§

impl<A> UnwindSafe for ContractObj<A>
where A: UnwindSafe,

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<C> FeaturesModule for C
where C: AutoImpl,

source§

fn get_feature_flag(&self, feature_name: FeatureName<'_>) -> u8

source§

fn set_feature_flag(&self, feature_name: FeatureName<'_>, value: u8)

source§

fn check_feature_on(&self, feature_name: &'static [u8], default: bool)

source§

fn set_feature_flag_endpoint( &self, feature_name: Vec<u8>, value: bool ) -> SCResult<()>

source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<M, F> ManagedFrom<M, F> for F
where M: ManagedTypeApi,

source§

fn managed_from(_: M, t: F) -> F

source§

impl<M, F, T> ManagedInto<M, T> for F
where T: ManagedFrom<M, F>, M: ManagedTypeApi,

source§

fn managed_into(self, api: M) -> T

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.