Trait sp_blockchain::HeaderMetadata [−][src]
pub trait HeaderMetadata<Block: BlockT> { type Error; fn header_metadata(
&self,
hash: Block::Hash
) -> Result<CachedHeaderMetadata<Block>, Self::Error>; fn insert_header_metadata(
&self,
hash: Block::Hash,
header_metadata: CachedHeaderMetadata<Block>
); fn remove_header_metadata(&self, hash: Block::Hash); }
Expand description
Handles header metadata: hash, number, parent hash, etc.
Associated Types
Required methods
fn header_metadata(
&self,
hash: Block::Hash
) -> Result<CachedHeaderMetadata<Block>, Self::Error>
fn insert_header_metadata(
&self,
hash: Block::Hash,
header_metadata: CachedHeaderMetadata<Block>
)
fn remove_header_metadata(&self, hash: Block::Hash)