pub struct CellSlice<'a, C: CellFamily> { /* private fields */ }
Expand description

A read-only view for a subcell of a cell

Implementations§

Constructs a new cell slice from the specified cell.

Computes cell type from descriptor bytes.

Computes the cell level from the level mask.

Computes the level mask from the descriptor bytes.

Returns whether there are no bits of data left.

Returns whether threre are no references left.

Returns the number of remaining references in the slice.

Returns the number of remaining bits of data in the slice.

Returns the start of the data window.

Tries to advance the start of the data window, returns false if bits is greater than the remainder.

Tries to read the bit at the specified offset (relative to the current bits window).

Tries to read the next bit, incrementing the bits window start.

Returns a small subset of bits (0..=8) starting from the offset.

Tries to read the next small subset of bits (0..=8), incrementing the bits window start.

Reads u8 starting from the offset.

Tries to read the next u8, incrementing the bits window start.

Reads u16 starting from the offset.

Tries to read the next u16, incrementing the bits window start.

Reads u32 starting from the offset.

Tries to read the next u32, incrementing the bits window start.

Reads u64 starting from the offset.

Tries to read the next u64, incrementing the bits window start.

Reads u128 starting from the offset.

Tries to read the next u128, incrementing the bits window start.

Reads 32 bytes starting from the offset.

Tries to read the next 32 bytes, incrementing the bits window start.

Returns a reference to the Nth child cell (relative to this slice’s refs window).

Returns the Nth child cell (relative to this slice’s refs window).

Creates an iterator through child nodes.

Converts this slice into an iterator through child nodes.

Returns a reference to the next child cell (relative to this slice’s refs window), incrementing the refs window start.

Returns the next child cell (relative to this slice’s refs window), incrementing the refs window start.

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

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

Should always be Self
The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.