pub trait CompatibleDigestItem: Sized {
// Required methods
fn babe_pre_digest(seal: PreDigest) -> Self;
fn as_babe_pre_digest(&self) -> Option<PreDigest>;
fn babe_seal(signature: AuthoritySignature) -> Self;
fn as_babe_seal(&self) -> Option<AuthoritySignature>;
fn as_next_epoch_descriptor(&self) -> Option<NextEpochDescriptor>;
fn as_next_config_descriptor(&self) -> Option<NextConfigDescriptor>;
}
Expand description
A digest item which is usable with BABE consensus.
Required Methods§
Sourcefn babe_pre_digest(seal: PreDigest) -> Self
fn babe_pre_digest(seal: PreDigest) -> Self
Construct a digest item which contains a BABE pre-digest.
Sourcefn as_babe_pre_digest(&self) -> Option<PreDigest>
fn as_babe_pre_digest(&self) -> Option<PreDigest>
If this item is an BABE pre-digest, return it.
Sourcefn babe_seal(signature: AuthoritySignature) -> Self
fn babe_seal(signature: AuthoritySignature) -> Self
Construct a digest item which contains a BABE seal.
Sourcefn as_babe_seal(&self) -> Option<AuthoritySignature>
fn as_babe_seal(&self) -> Option<AuthoritySignature>
If this item is a BABE signature, return the signature.
Sourcefn as_next_epoch_descriptor(&self) -> Option<NextEpochDescriptor>
fn as_next_epoch_descriptor(&self) -> Option<NextEpochDescriptor>
If this item is a BABE epoch descriptor, return it.
Sourcefn as_next_config_descriptor(&self) -> Option<NextConfigDescriptor>
fn as_next_config_descriptor(&self) -> Option<NextConfigDescriptor>
If this item is a BABE config descriptor, return it.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.