Trait pallet_beefy_mmr::pallet::Config [−][src]
pub trait Config: Config + Config {
type LeafVersion: Get<MmrLeafVersion>;
type BeefyAuthorityToMerkleLeaf: Convert<<Self as Config>::BeefyId, Vec<u8>>;
type ParachainHeads: ParachainHeadsProvider;
}
Expand description
The module’s configuration trait.
Associated Types
type LeafVersion: Get<MmrLeafVersion>
type LeafVersion: Get<MmrLeafVersion>
Current leaf version.
Specifies the version number added to every leaf that get’s appended to the MMR.
Read more in MmrLeafVersion
docs about versioning leaves.
Convert BEEFY AuthorityId to a form that would end up in the Merkle Tree.
For instance for ECDSA (secp256k1) we want to store uncompressed public keys (65 bytes) and later to Ethereum Addresses (160 bits) to simplify using them on Ethereum chain, but the rest of the Substrate codebase is storing them compressed (33 bytes) for efficiency reasons.
Retrieve a list of current parachain heads.
The trait is implemented for paras
module, but since not all chains might have
parachains, and we want to keep the MMR leaf structure uniform, it’s possible to use
()
as well to simply put dummy data to the leaf.