zink::storage::value

Trait Storage

source
pub trait Storage {
    type Value: StorageValue + Asm;

    const STORAGE_KEY: [u8; 32];
    const STORAGE_SLOT: i32;

    // Provided methods
    fn get() -> Self::Value { ... }
    fn set(value: Self::Value) { ... }
}
Expand description

Storage trait. Currently not for public use

Required Associated Constants§

Required Associated Types§

Provided Methods§

source

fn get() -> Self::Value

Get value from storage.

source

fn set(value: Self::Value)

Set value to storage.

Object Safety§

This trait is not object safe.

Implementors§