Skip to main content

BlobMessage

Struct BlobMessage 

Source
pub struct BlobMessage {
    pub id: Hash,
    pub offset: u64,
}
Expand description

A 40-byte profile entry identifying a blob by its 32-byte Merkle root [Hash] and a logical byte offset.

Fields§

§id: Hash§offset: u64

Readahead-aligned logical byte offset within the blob. Only the start offset (without length) is stored because replay prefetches a single page at offset and relies on the pager’s readahead to fault in the full window.

Trait Implementations§

Source§

impl Clone for BlobMessage

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for BlobMessage

Source§

impl Debug for BlobMessage

Source§

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

Formats the value using the given formatter. Read more
Source§

impl Eq for BlobMessage

Source§

impl Hash for BlobMessage

Source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl Message for BlobMessage

Source§

type IdType = GenericDigest<FuchsiaMerkleMarker>

Source§

fn id(&self) -> Self::IdType

Source§

fn offset(&self) -> u64

Source§

fn encode_to(&self, dest: MutPtrByteSlice<'_>)

Source§

fn decode_from(src: PtrByteSlice<'_>) -> Self

Source§

fn is_zeroes(&self) -> bool

Source§

fn is_open_marker(&self) -> bool

Source§

fn encode_to_vmo( messages: impl IntoIterator<Item = impl Borrow<Self>>, block_size: usize, ) -> Result<Vmo, Status>

Encodes messages into a new zx::Vmo packed into block_size-aligned blocks (typically 4 KiB) without crossing block_size boundaries. Any trailing bytes in a block that cannot fit a full message are zero-padded.
Source§

fn decode_from_vmo( vmo: Vmo, block_size: usize, ) -> Result<DecodedMessageIter<Self>, Status>

Returns an iterator that lazily decodes messages from vmo one block_size-aligned block at a time. An all-zero message (Self::is_zeroes()) marks the end of the recorded stream.
Source§

impl PartialEq for BlobMessage

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for BlobMessage

Auto Trait Implementations§

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> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. 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> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
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, !>

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.