Struct oasis_runtime_sdk_contracts::types::InstanceId
source · pub struct InstanceId(/* private fields */);
Expand description
Unique deployed code instance identifier.
Implementations§
source§impl InstanceId
impl InstanceId
sourcepub fn increment(&self) -> InstanceId
pub fn increment(&self) -> InstanceId
Return the next identifier in sequence.
sourcepub fn to_storage_key(self) -> [u8; 8]
pub fn to_storage_key(self) -> [u8; 8]
Convert identifier to storage key representation.
Trait Implementations§
source§impl Clone for InstanceId
impl Clone for InstanceId
source§fn clone(&self) -> InstanceId
fn clone(&self) -> InstanceId
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for InstanceId
impl Debug for InstanceId
source§impl Decode for InstanceId
impl Decode for InstanceId
source§fn try_default() -> Result<InstanceId, DecodeError>
fn try_default() -> Result<InstanceId, DecodeError>
Try to decode from a missing/null/undefined value.
source§fn try_from_cbor_value(value: Value) -> Result<InstanceId, DecodeError>
fn try_from_cbor_value(value: Value) -> Result<InstanceId, DecodeError>
Try to decode from a given CBOR value.
§fn try_from_cbor_value_default(value: Value) -> Result<Self, DecodeError>where
Self: Sized,
fn try_from_cbor_value_default(value: Value) -> Result<Self, DecodeError>where
Self: Sized,
Try to decode from a given CBOR value, calling
try_default
in case the value is null or
undefined.source§impl Default for InstanceId
impl Default for InstanceId
source§fn default() -> InstanceId
fn default() -> InstanceId
Returns the “default value” for a type. Read more
source§impl Encode for InstanceId
impl Encode for InstanceId
source§impl From<u64> for InstanceId
impl From<u64> for InstanceId
source§fn from(v: u64) -> InstanceId
fn from(v: u64) -> InstanceId
Converts to this type from the input type.
source§impl PartialEq for InstanceId
impl PartialEq for InstanceId
source§fn eq(&self, other: &InstanceId) -> bool
fn eq(&self, other: &InstanceId) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Copy for InstanceId
impl Eq for InstanceId
impl StructuralPartialEq for InstanceId
Auto Trait Implementations§
impl Freeze for InstanceId
impl RefUnwindSafe for InstanceId
impl Send for InstanceId
impl Sync for InstanceId
impl Unpin for InstanceId
impl UnwindSafe for InstanceId
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
source§impl<T> CloneToUninit for Twhere
T: Copy,
impl<T> CloneToUninit for Twhere
T: Copy,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.