pub trait BlockProductionLogApi<Block: BlockT, Author, Moment>: Core<Block>where
Author: Decode,
Moment: Encode,{
// Provided method
fn get_author(
&self,
__runtime_api_at_param__: <Block as BlockT>::Hash,
moment: &Moment,
) -> Result<Option<Author>, ApiError> { ... }
}Expand description
Runtime API exposing data required for the BlockAuthorInherentProvider to operate. Type parameters:
Author: type representing a committee member eligible to be a block author. This type should correspond to what is configured as the block author type used by the pallet.
Provided Methods§
Function returning the current block’s author.
Its implementation must either use data exposed by the consensus mechanism used by the Partner Chain, independently calculate it, or obtain it from another source.
Parameters:
moment: value representing the current block’s moment in time. It will typically be a timestamp or slot but can be any other value that is needed to decide the current block’s author and can be passed from the node.