pub trait CustomStorageAccess {
Show 20 methods fn custom_storage<S: 'static>(&self) -> Result<Ref<'_, &S>, GetStorage>; fn custom_storage_by_id(
        &self,
        storage_id: StorageId
    ) -> Result<Ref<'_, &dyn Storage>, GetStorage>; fn custom_storage_mut<S: 'static>(
        &self
    ) -> Result<RefMut<'_, &mut S>, GetStorage>; fn custom_storage_mut_by_id(
        &self,
        storage_id: StorageId
    ) -> Result<RefMut<'_, &mut (dyn Storage + 'static)>, GetStorage>; fn custom_storage_or_insert<S, F>(
        &self,
        f: F
    ) -> Result<Ref<'_, &S>, GetStorage>
    where
        S: 'static + Storage + Send + Sync,
        F: FnOnce() -> S
; fn custom_storage_or_insert_by_id<S, F>(
        &self,
        storage_id: StorageId,
        f: F
    ) -> Result<Ref<'_, &S>, GetStorage>
    where
        S: 'static + Storage + Send + Sync,
        F: FnOnce() -> S
; fn custom_storage_or_insert_non_send<S, F>(
        &self,
        f: F
    ) -> Result<Ref<'_, &S>, GetStorage>
    where
        S: 'static + Storage + Sync,
        F: FnOnce() -> S
; fn custom_storage_or_insert_non_send_by_id<S, F>(
        &self,
        storage_id: StorageId,
        f: F
    ) -> Result<Ref<'_, &S>, GetStorage>
    where
        S: 'static + Storage + Sync,
        F: FnOnce() -> S
; fn custom_storage_or_insert_non_sync<S, F>(
        &self,
        f: F
    ) -> Result<Ref<'_, &S>, GetStorage>
    where
        S: 'static + Storage + Send,
        F: FnOnce() -> S
; fn custom_storage_or_insert_non_sync_by_id<S, F>(
        &self,
        storage_id: StorageId,
        f: F
    ) -> Result<Ref<'_, &S>, GetStorage>
    where
        S: 'static + Storage + Send,
        F: FnOnce() -> S
; fn custom_storage_or_insert_non_send_sync<S, F>(
        &self,
        f: F
    ) -> Result<Ref<'_, &S>, GetStorage>
    where
        S: 'static + Storage,
        F: FnOnce() -> S
; fn custom_storage_or_insert_non_send_sync_by_id<S, F>(
        &self,
        storage_id: StorageId,
        f: F
    ) -> Result<Ref<'_, &S>, GetStorage>
    where
        S: 'static + Storage,
        F: FnOnce() -> S
; fn custom_storage_or_insert_mut<S, F>(
        &self,
        f: F
    ) -> Result<RefMut<'_, &mut S>, GetStorage>
    where
        S: 'static + Storage + Send + Sync,
        F: FnOnce() -> S
; fn custom_storage_or_insert_mut_by_id<S, F>(
        &self,
        storage_id: StorageId,
        f: F
    ) -> Result<RefMut<'_, &mut S>, GetStorage>
    where
        S: 'static + Storage + Send + Sync,
        F: FnOnce() -> S
; fn custom_storage_or_insert_non_send_mut<'a, S, F>(
        &'a self,
        f: F
    ) -> Result<RefMut<'a, &'a mut S>, GetStorage>
    where
        S: 'static + Storage + Sync,
        F: FnOnce() -> S
; fn custom_storage_or_insert_non_send_mut_by_id<'a, S, F>(
        &'a self,
        storage_id: StorageId,
        f: F
    ) -> Result<RefMut<'a, &'a mut S>, GetStorage>
    where
        S: 'static + Storage + Sync,
        F: FnOnce() -> S
; fn custom_storage_or_insert_non_sync_mut<'a, S, F>(
        &'a self,
        f: F
    ) -> Result<RefMut<'a, &'a mut S>, GetStorage>
    where
        S: 'static + Storage + Send,
        F: FnOnce() -> S
; fn custom_storage_or_insert_non_sync_mut_by_id<'a, S, F>(
        &'a self,
        storage_id: StorageId,
        f: F
    ) -> Result<RefMut<'a, &'a mut S>, GetStorage>
    where
        S: 'static + Storage + Send,
        F: FnOnce() -> S
; fn custom_storage_or_insert_non_send_sync_mut<'a, S, F>(
        &'a self,
        f: F
    ) -> Result<RefMut<'a, &'a mut S>, GetStorage>
    where
        S: 'static + Storage,
        F: FnOnce() -> S
; fn custom_storage_or_insert_non_send_sync_mut_by_id<'a, S, F>(
        &'a self,
        storage_id: StorageId,
        f: F
    ) -> Result<RefMut<'a, &'a mut S>, GetStorage>
    where
        S: 'static + Storage,
        F: FnOnce() -> S
;
}
Expand description

Low level access to storage.

Useful with custom storage or to define custom views.

Required Methods

Returns a Ref to the requested S storage.

Returns a Ref to the requested S storage using a StorageId.

Returns a RefMut to the requested S storage.

Returns a RefMut to the requested S storage using a StorageId.

Returns a Ref to the requested S storage and create it if it does not exist.

Returns a Ref to the requested S storage using a StorageId and create it if it does not exist.

Returns a Ref to the requested S storage and create it if it does not exist.

Returns a Ref to the requested S storage using a StorageId and create it if it does not exist.

Returns a Ref to the requested S storage and create it if it does not exist.

Returns a Ref to the requested S storage using a StorageId and create it if it does not exist.

Returns a Ref to the requested S storage and create it if it does not exist.

Returns a Ref to the requested S storage using a StorageId and create it if it does not exist.

Returns a RefMut to the requested S storage and create it if it does not exist.

Returns a RefMut to the requested S storage using a StorageId and create it if it does not exist.

Returns a RefMut to the requested S storage and create it if it does not exist.

Returns a RefMut to the requested S storage using a StorageId and create it if it does not exist.

Returns a RefMut to the requested S storage and create it if it does not exist.

Returns a RefMut to the requested S storage using a StorageId and create it if it does not exist.

Returns a RefMut to the requested S storage and create it if it does not exist.

Returns a RefMut to the requested S storage using a StorageId and create it if it does not exist.

Implementors