Trait sp_consensus_aura::AuraApi [−][src]
pub trait AuraApi<Block: BlockT, AuthorityId: Codec>: Core<Block> { fn slot_duration(
&self,
__runtime_api_at_param__: &BlockId<Block>
) -> Result<SlotDuration, ApiError> { ... } fn slot_duration_with_context(
&self,
__runtime_api_at_param__: &BlockId<Block>,
context: ExecutionContext
) -> Result<SlotDuration, ApiError> { ... } fn authorities(
&self,
__runtime_api_at_param__: &BlockId<Block>
) -> Result<Vec<AuthorityId>, ApiError> { ... } fn authorities_with_context(
&self,
__runtime_api_at_param__: &BlockId<Block>,
context: ExecutionContext
) -> Result<Vec<AuthorityId>, ApiError> { ... } }
Expand description
API necessary for block authorship with aura.
Provided methods
fn slot_duration(
&self,
__runtime_api_at_param__: &BlockId<Block>
) -> Result<SlotDuration, ApiError>
fn slot_duration(
&self,
__runtime_api_at_param__: &BlockId<Block>
) -> Result<SlotDuration, ApiError>
Returns the slot duration for Aura.
Currently, only the value provided by this type at genesis will be used.
fn slot_duration_with_context(
&self,
__runtime_api_at_param__: &BlockId<Block>,
context: ExecutionContext
) -> Result<SlotDuration, ApiError>
fn slot_duration_with_context(
&self,
__runtime_api_at_param__: &BlockId<Block>,
context: ExecutionContext
) -> Result<SlotDuration, ApiError>
Returns the slot duration for Aura.
Currently, only the value provided by this type at genesis will be used.
Trait Implementations
Implementors
impl<__SR_API_BLOCK__: BlockT + UnwindSafe + RefUnwindSafe, RuntimeApiImplCall: CallApiAt<__SR_API_BLOCK__> + 'static> AuraApi<__SR_API_BLOCK__, Public> for RuntimeApiImpl<__SR_API_BLOCK__, RuntimeApiImplCall> where
RuntimeApiImplCall::StateBackend: StateBackend<HashFor<__SR_API_BLOCK__>>,
SlotDuration: UnwindSafe + RefUnwindSafe,
Vec<AuraId>: UnwindSafe + RefUnwindSafe,
__SR_API_BLOCK__::Header: UnwindSafe + RefUnwindSafe,
impl<__SR_API_BLOCK__: BlockT + UnwindSafe + RefUnwindSafe, RuntimeApiImplCall: CallApiAt<__SR_API_BLOCK__> + 'static> AuraApi<__SR_API_BLOCK__, Public> for RuntimeApiImpl<__SR_API_BLOCK__, RuntimeApiImplCall> where
RuntimeApiImplCall::StateBackend: StateBackend<HashFor<__SR_API_BLOCK__>>,
SlotDuration: UnwindSafe + RefUnwindSafe,
Vec<AuraId>: UnwindSafe + RefUnwindSafe,
__SR_API_BLOCK__::Header: UnwindSafe + RefUnwindSafe,
impl<__SR_API_BLOCK__: BlockT + UnwindSafe + RefUnwindSafe, RuntimeApiImplCall: CallApiAt<__SR_API_BLOCK__> + 'static> AuraApi<__SR_API_BLOCK__, Public> for RuntimeApiImpl<__SR_API_BLOCK__, RuntimeApiImplCall> where
RuntimeApiImplCall::StateBackend: StateBackend<HashFor<__SR_API_BLOCK__>>,
SlotDuration: UnwindSafe + RefUnwindSafe,
Vec<AuraId>: UnwindSafe + RefUnwindSafe,
__SR_API_BLOCK__::Header: UnwindSafe + RefUnwindSafe,
impl<__SR_API_BLOCK__: BlockT + UnwindSafe + RefUnwindSafe, RuntimeApiImplCall: CallApiAt<__SR_API_BLOCK__> + 'static> AuraApi<__SR_API_BLOCK__, Public> for RuntimeApiImpl<__SR_API_BLOCK__, RuntimeApiImplCall> where
RuntimeApiImplCall::StateBackend: StateBackend<HashFor<__SR_API_BLOCK__>>,
SlotDuration: UnwindSafe + RefUnwindSafe,
Vec<AuraId>: UnwindSafe + RefUnwindSafe,
__SR_API_BLOCK__::Header: UnwindSafe + RefUnwindSafe,