ouisync/protocol/
mod.rs

1//! Datatypes for the ouisync protocol and for interoperability between the network layer and the
2//! storage later
3
4mod block;
5mod bump;
6mod inner_node;
7mod leaf_node;
8mod locator;
9mod proof;
10mod repository;
11mod root_node;
12mod storage_size;
13mod summary;
14
15#[cfg(test)]
16pub(crate) mod test_utils;
17
18pub use self::block::{BLOCK_RECORD_SIZE, BLOCK_SIZE};
19pub use self::{
20    proof::{Proof, UntrustedProof},
21    repository::RepositoryId,
22    root_node::RootNode,
23    storage_size::StorageSize,
24    summary::{MultiBlockPresence, NodeState, SingleBlockPresence, Summary},
25};
26
27pub(crate) use self::{
28    block::{Block, BlockContent, BlockId, BlockNonce},
29    bump::Bump,
30    inner_node::{get_bucket, InnerNode, InnerNodes, EMPTY_INNER_HASH, INNER_LAYER_COUNT},
31    leaf_node::{LeafNode, LeafNodes, EMPTY_LEAF_HASH},
32    locator::Locator,
33    proof::ProofError,
34    root_node::{RootNodeFilter, RootNodeKind},
35};
36
37#[cfg(test)]
38pub(crate) use self::{block::BLOCK_NONCE_SIZE, root_node::SnapshotId};