pub trait Outboard {
    // Required methods
    fn root(&self) -> Hash;
    fn tree(&self) -> BaoTree;
    fn load(&self, node: TreeNode) -> Result<Option<(Hash, Hash)>>;
}
Expand description

An outboard is a just a thing that knows how big it is and can get you the hashes for a node.

Required Methods§

source

fn root(&self) -> Hash

The root hash

source

fn tree(&self) -> BaoTree

The tree. This contains the information about the size of the file and the block size.

source

fn load(&self, node: TreeNode) -> Result<Option<(Hash, Hash)>>

load the hash pair for a node

Implementations on Foreign Types§

source§

impl<O: Outboard> Outboard for &O

source§

fn root(&self) -> Hash

source§

fn tree(&self) -> BaoTree

source§

fn load(&self, node: TreeNode) -> Result<Option<(Hash, Hash)>>

source§

impl<O: Outboard> Outboard for &mut O

source§

fn root(&self) -> Hash

source§

fn tree(&self) -> BaoTree

source§

fn load(&self, node: TreeNode) -> Result<Option<(Hash, Hash)>>

Implementors§