2020-08-15 16:12:26 -07:00
|
|
|
//! Blocks and block-related structures (heights, headers, etc.)
|
2019-09-10 13:27:10 -07:00
|
|
|
|
2020-08-15 15:56:33 -07:00
|
|
|
// block::block is done on purpose and is the most representative name
|
|
|
|
#![allow(clippy::module_inception)]
|
|
|
|
|
|
|
|
mod block;
|
2020-06-25 09:18:05 -07:00
|
|
|
mod hash;
|
|
|
|
mod header;
|
2020-08-14 23:51:41 -07:00
|
|
|
mod height;
|
2020-08-15 16:12:26 -07:00
|
|
|
mod root_hash;
|
2020-06-25 09:18:05 -07:00
|
|
|
mod serialize;
|
|
|
|
|
2020-08-15 20:57:59 -07:00
|
|
|
pub mod merkle;
|
|
|
|
|
2020-01-31 21:27:51 -08:00
|
|
|
#[cfg(test)]
|
|
|
|
mod tests;
|
2020-01-31 18:02:02 -08:00
|
|
|
|
2020-08-15 15:56:33 -07:00
|
|
|
pub use block::Block;
|
2020-06-25 09:18:05 -07:00
|
|
|
pub use hash::BlockHeaderHash;
|
|
|
|
pub use header::BlockHeader;
|
2020-08-14 23:51:41 -07:00
|
|
|
pub use height::BlockHeight;
|
2020-08-15 16:12:26 -07:00
|
|
|
pub use root_hash::RootHash;
|
2019-09-24 22:14:48 -07:00
|
|
|
|
2020-07-14 20:21:06 -07:00
|
|
|
/// The error type for Block checks.
|
2020-08-15 15:56:33 -07:00
|
|
|
// XXX try to remove this -- block checks should be done in zebra-consensus
|
|
|
|
type Error = Box<dyn std::error::Error + Send + Sync + 'static>;
|