#[non_exhaustive]pub enum StorageKey {
Gas,
StateHash,
PageInfo(PageAddr),
VmSpec,
VideoMode,
AudioMode,
ExecEnvRef,
Owner,
ResidentPages,
}Expand description
Storage keys used by CoreVM.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Gas
Inner VM gas.
StateHash
The hash of this CoreVM instance.
Computed with corevm_engine::compute_state_hash.
PageInfo(PageAddr)
The last known metadata of a memory page with the specified address.
An instance of PageInfo.
VmSpec
The output data specification of the VM.
An instance of VmSpec.
VideoMode
The current video mode.
An instance of VideoMode.
AudioMode
The current audio mode.
An instance of AudioMode.
ExecEnvRef
Execution environment location in the virtual file system.
The environment (ExecEnv) itself is stored as a file.
Owner
The owner of this CoreVM instance; they can reset the code.
ResidentPages
The pages currently in active use by the program.
Trait Implementations§
Source§impl Clone for StorageKey
impl Clone for StorageKey
Source§fn clone(&self) -> StorageKey
fn clone(&self) -> StorageKey
Returns a duplicate 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 StorageKey
impl Debug for StorageKey
Source§impl Encode for StorageKey
impl Encode for StorageKey
Source§fn size_hint(&self) -> usize
fn size_hint(&self) -> usize
If possible give a hint of expected size of the encoding. Read more
Source§fn encode_to<__CodecOutputEdqy: Output + ?Sized>(
&self,
__codec_dest_edqy: &mut __CodecOutputEdqy,
)
fn encode_to<__CodecOutputEdqy: Output + ?Sized>( &self, __codec_dest_edqy: &mut __CodecOutputEdqy, )
Convert self to a slice and append it to the destination.
Source§fn using_encoded<R, F>(&self, f: F) -> R
fn using_encoded<R, F>(&self, f: F) -> R
Convert self to a slice and then invoke the given closure with it.
Source§fn encoded_size(&self) -> usize
fn encoded_size(&self) -> usize
Calculates the encoded size. Read more
Source§impl Hash for StorageKey
impl Hash for StorageKey
Source§impl Ord for StorageKey
impl Ord for StorageKey
Source§fn cmp(&self, other: &StorageKey) -> Ordering
fn cmp(&self, other: &StorageKey) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for StorageKey
impl PartialEq for StorageKey
Source§impl PartialOrd for StorageKey
impl PartialOrd for StorageKey
impl Copy for StorageKey
impl EncodeLike for StorageKey
impl Eq for StorageKey
impl StructuralPartialEq for StorageKey
Auto Trait Implementations§
impl Freeze for StorageKey
impl RefUnwindSafe for StorageKey
impl Send for StorageKey
impl Sync for StorageKey
impl Unpin for StorageKey
impl UnwindSafe for StorageKey
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