pub struct StorageValue<T: WordValue> {
pub slot: StorageSlotId,
/* private fields */
}Expand description
Typed access to a single account storage value.
Fields§
§slot: StorageSlotIdThe underlying storage slot id.
Implementations§
Source§impl<T: WordValue> StorageValue<T>
impl<T: WordValue> StorageValue<T>
Sourcepub const fn new(slot: StorageSlotId) -> Self
pub const fn new(slot: StorageSlotId) -> Self
Creates a new typed storage-value handle for slot.
Trait Implementations§
Source§impl<T: Clone + WordValue> Clone for StorageValue<T>
impl<T: Clone + WordValue> Clone for StorageValue<T>
Source§fn clone(&self) -> StorageValue<T>
fn clone(&self) -> StorageValue<T>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl<T: Copy + WordValue> Copy for StorageValue<T>
impl<T: Eq + WordValue> Eq for StorageValue<T>
Source§impl<T: WordValue> From<StorageSlotId> for StorageValue<T>
impl<T: WordValue> From<StorageSlotId> for StorageValue<T>
Source§fn from(slot: StorageSlotId) -> Self
fn from(slot: StorageSlotId) -> Self
Converts to this type from the input type.
impl<T: PartialEq + WordValue> StructuralPartialEq for StorageValue<T>
Auto Trait Implementations§
impl<T> Freeze for StorageValue<T>where
PhantomData<T>: Freeze,
impl<T> RefUnwindSafe for StorageValue<T>where
PhantomData<T>: RefUnwindSafe,
impl<T> Send for StorageValue<T>where
PhantomData<T>: Send,
impl<T> Sync for StorageValue<T>where
PhantomData<T>: Sync,
impl<T> Unpin for StorageValue<T>where
PhantomData<T>: Unpin,
impl<T> UnsafeUnpin for StorageValue<T>where
PhantomData<T>: UnsafeUnpin,
impl<T> UnwindSafe for StorageValue<T>where
PhantomData<T>: UnwindSafe,
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more