pub trait Block:
Heightable
+ Digestible
+ Encode {
// Required method
fn parent(&self) -> Self::Digest;
}Expand description
Block is the interface for a block in the blockchain.
A block type that is also decoded, such as an application block received over the wire or
read from storage, must use a canonical encoding. Every byte sequence bytes accepted by
the decoder must satisfy encode(decode(bytes)) == bytes, and decoders must reject
alternate encodings of the same block.
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementations on Foreign Types§
Source§impl<B: Block> Block for Arc<B>
Available on neither commonware_stability_DELTA nor commonware_stability_EPSILON nor commonware_stability_GAMMA nor commonware_stability_RESERVED.
impl<B: Block> Block for Arc<B>
Available on neither
commonware_stability_DELTA nor commonware_stability_EPSILON nor commonware_stability_GAMMA nor commonware_stability_RESERVED.Source§impl<B: Block> Block for Digested<B>
Available on neither commonware_stability_DELTA nor commonware_stability_EPSILON nor commonware_stability_GAMMA nor commonware_stability_RESERVED.
impl<B: Block> Block for Digested<B>
Available on neither
commonware_stability_DELTA nor commonware_stability_EPSILON nor commonware_stability_GAMMA nor commonware_stability_RESERVED.