Trait StorageExternalities

Source
pub trait StorageExternalities<Error> {
    // Required methods
    fn read_storage(&self, key: &[u8]) -> Result<Option<Vec<u8>>, Error>;
    fn write_storage(&mut self, key: Vec<u8>, value: Vec<u8>);
    fn remove_storage(&mut self, key: &[u8]);
}
Expand description

Externalities for reading a key value based storage.

Required Methods§

Source

fn read_storage(&self, key: &[u8]) -> Result<Option<Vec<u8>>, Error>

Read storage value.

Source

fn write_storage(&mut self, key: Vec<u8>, value: Vec<u8>)

Write storage value.

Source

fn remove_storage(&mut self, key: &[u8])

Remove storage value.

Implementors§