Skip to main content

TreeEntryReader

Struct TreeEntryReader 

Source
pub struct TreeEntryReader<S: TreeByteSource> { /* private fields */ }
Expand description

Incremental HTR4 reader. Does not materialize a full Vec<TreeEntry>.

Implementations§

Source§

impl<S: TreeByteSource> TreeEntryReader<S>

Source

pub fn open( source: S, expected_id: ContentHash, resume: Option<&TreeResumeCursor>, ) -> Result<Self, TreeStreamError>

Source

pub fn header(&self) -> &TreeHeader

Source

pub fn bytes_read(&self) -> u64

Source

pub fn next_page( &mut self, limits: TreePageLimits, ) -> Result<Option<TreePage>, TreeStreamError>

Source

pub fn next_entry(&mut self) -> Result<Option<TreeEntry>, TreeStreamError>

Yield one decoded entry. Used by full-object collect without a page ceiling.

Source

pub fn finish_and_verify(&mut self) -> Result<(), TreeStreamError>

Trait Implementations§

Source§

impl<S: Debug + TreeByteSource> Debug for TreeEntryReader<S>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<S> Freeze for TreeEntryReader<S>
where S: Freeze,

§

impl<S> RefUnwindSafe for TreeEntryReader<S>
where S: RefUnwindSafe,

§

impl<S> Send for TreeEntryReader<S>
where S: Send,

§

impl<S> Sync for TreeEntryReader<S>
where S: Sync,

§

impl<S> Unpin for TreeEntryReader<S>
where S: Unpin,

§

impl<S> UnsafeUnpin for TreeEntryReader<S>
where S: UnsafeUnpin,

§

impl<S> UnwindSafe for TreeEntryReader<S>
where S: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.