pub struct BaoTree { /* private fields */ }Expand description
Defines a Bao tree.
This is just the specification of the tree, it does not contain any actual data
Implementations§
source§impl BaoTree
 
impl BaoTree
sourcepub fn post_order_chunks_iter(&self) -> PostOrderChunkIter ⓘ
 
pub fn post_order_chunks_iter(&self) -> PostOrderChunkIter ⓘ
Traverse the entire tree in post order as BaoChunks
This iterator is used by both the sync and async io code for computing an outboard from existing data
sourcepub fn ranges_pre_order_chunks_ref<'a>(
    &self,
    ranges: &'a RangeSetRef<ChunkNum>,
    min_level: u8
) -> PreOrderChunkIterRef<'a> ⓘ
 
pub fn ranges_pre_order_chunks_ref<'a>( &self, ranges: &'a RangeSetRef<ChunkNum>, min_level: u8 ) -> PreOrderChunkIterRef<'a> ⓘ
Traverse the part of the tree that is relevant for a ranges querys in pre order as BaoChunks
This iterator is used by both the sync and async io code for encoding from an outboard and ranges as well as decoding an encoded stream.
sourcepub fn post_order_nodes_iter(&self) -> PostOrderNodeIter ⓘ
 
pub fn post_order_nodes_iter(&self) -> PostOrderNodeIter ⓘ
Traverse the entire tree in post order as TreeNodes
This is mostly used internally by the PostOrderChunkIter
sourcepub fn ranges_pre_order_nodes_iter<'a>(
    &self,
    ranges: &'a RangeSetRef<ChunkNum>,
    min_level: u8
) -> PreOrderPartialIterRef<'a> ⓘ
 
pub fn ranges_pre_order_nodes_iter<'a>( &self, ranges: &'a RangeSetRef<ChunkNum>, min_level: u8 ) -> PreOrderPartialIterRef<'a> ⓘ
Traverse the part of the tree that is relevant for a ranges querys in pre order as NodeInfos
This is mostly used internally by the PreOrderChunkIterRef
sourcepub fn new_with_start_chunk(
    size: ByteNum,
    block_size: BlockSize,
    start_chunk: ChunkNum
) -> BaoTree
 
pub fn new_with_start_chunk( size: ByteNum, block_size: BlockSize, start_chunk: ChunkNum ) -> BaoTree
Create a new BaoTree with a start chunk
This is used for trees that are part of a larger file. The start chunk is the chunk number of the first chunk in the tree.
This is mostly used internally.