Trait GovernedMapIDPApi

Source
pub trait GovernedMapIDPApi<Block: BlockT>: Core<Block> {
    // Provided methods
    fn is_initialized(
        &self,
        __runtime_api_at_param__: <Block as BlockT>::Hash,
    ) -> Result<bool, ApiError> { ... }
    fn get_current_state(
        &self,
        __runtime_api_at_param__: <Block as BlockT>::Hash,
    ) -> Result<BTreeMap<String, ByteString>, ApiError> { ... }
    fn get_main_chain_scripts(
        &self,
        __runtime_api_at_param__: <Block as BlockT>::Hash,
    ) -> Result<Option<MainChainScriptsV1>, ApiError> { ... }
    fn get_pallet_version(
        &self,
        __runtime_api_at_param__: <Block as BlockT>::Hash,
    ) -> Result<u32, ApiError> { ... }
}
Expand description

Runtime API exposing data required for the GovernedMapInherentDataProvider to operate.

Provided Methods§

Source

fn is_initialized( &self, __runtime_api_at_param__: <Block as BlockT>::Hash, ) -> Result<bool, ApiError>

Returns initialization state of the pallet

Source

fn get_current_state( &self, __runtime_api_at_param__: <Block as BlockT>::Hash, ) -> Result<BTreeMap<String, ByteString>, ApiError>

Returns all mappings currently stored in the pallet

Source

fn get_main_chain_scripts( &self, __runtime_api_at_param__: <Block as BlockT>::Hash, ) -> Result<Option<MainChainScriptsV1>, ApiError>

Returns the main chain scripts currently set in the pallet or None otherwise

Source

fn get_pallet_version( &self, __runtime_api_at_param__: <Block as BlockT>::Hash, ) -> Result<u32, ApiError>

Returns the current version of the pallet, 1-based.

Trait Implementations§

Source§

impl<Block: BlockT> RuntimeApiInfo for dyn GovernedMapIDPApi<Block>

Source§

const ID: [u8; 8]

The identifier of the runtime api.
Source§

const VERSION: u32 = 1u32

The version of the runtime api.

Implementors§