Trait fabric_support::traits::StorageInstance[][src]

pub trait StorageInstance {
    const STORAGE_PREFIX: &'static str;

    fn noble_prefix() -> &'static str;
}

An instance of a storage in a noble.

Define an instance for an individual storage inside a noble. The noble prefix is used to isolate the storage between nobles, and the storage prefix is used to isolate storages inside a noble.

NOTE: These information can be used to define storages in noble such as a StorageMap which can use keys after twox_128(noble_prefix())++twox_128(STORAGE_PREFIX)

Associated Constants

const STORAGE_PREFIX: &'static str[src]

Prefix given to a storage to isolate from other storages in the noble.

Loading content...

Required methods

fn noble_prefix() -> &'static str[src]

Prefix of a noble to isolate it from other nobles.

Loading content...

Implementors

Loading content...