Struct fuel_core_storage::tables::ContractsAssets
source · pub struct ContractsAssets;
Expand description
The storage table for contract’s assets balances.
Lifetime is for optimization to avoid clone
.
Trait Implementations§
source§impl Mappable for ContractsAssets
impl Mappable for ContractsAssets
§type Key = <ContractsAssets as Mappable>::OwnedKey
type Key = <ContractsAssets as Mappable>::OwnedKey
The key type is used during interaction with the storage. In most cases, it is the same
as
Self::OwnedKey
.§type OwnedKey = ContractsAssetKey
type OwnedKey = ContractsAssetKey
The owned type of the
Key
retrieving from the storage.§type Value = u64
type Value = u64
The value type is used while setting the value to the storage. In most cases, it is the same
as
Self::OwnedValue
, but it is without restriction and can be used for performance
optimizations.§type OwnedValue = <ContractsAssets as Mappable>::Value
type OwnedValue = <ContractsAssets as Mappable>::Value
The owned type of the
Value
retrieving from the storage.source§impl MerkleRootStorage<ContractId, ContractsAssets> for MemoryStorage
impl MerkleRootStorage<ContractId, ContractsAssets> for MemoryStorage
source§impl StorageInspect<ContractsAssets> for MemoryStorage
impl StorageInspect<ContractsAssets> for MemoryStorage
type Error = Infallible
source§fn get(
&self,
key: &<ContractsAssets as Mappable>::Key
) -> Result<Option<Cow<'_, u64>>, Infallible>
fn get( &self, key: &<ContractsAssets as Mappable>::Key ) -> Result<Option<Cow<'_, u64>>, Infallible>
Retrieve
Cow<Value>
such as Key->Value
.source§fn contains_key(
&self,
key: &<ContractsAssets as Mappable>::Key
) -> Result<bool, Infallible>
fn contains_key( &self, key: &<ContractsAssets as Mappable>::Key ) -> Result<bool, Infallible>
Return
true
if there is a Key
mapping to a value in the storage.source§impl StorageMutate<ContractsAssets> for MemoryStorage
impl StorageMutate<ContractsAssets> for MemoryStorage
Auto Trait Implementations§
impl RefUnwindSafe for ContractsAssets
impl Send for ContractsAssets
impl Sync for ContractsAssets
impl Unpin for ContractsAssets
impl UnwindSafe for ContractsAssets
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