pub struct ManifestHeader {
pub drop_store_version: u16,
pub metadata_version: u16,
pub manifest_version: u16,
}Expand description
Parsed 16-byte manifest header.
Field widths are fixed: magic (4) + three u16 LE versions (6) +
reserved (6). Reserved MUST be zero. The reserved width reconciles
the spec’s “first 16 bytes” framing with the field table (which
otherwise sums to 14) — see bit-level/35-manifest-header.md and
limnifs/spec#13.
Fields§
§drop_store_version: u16§metadata_version: u16§manifest_version: u16Implementations§
Source§impl ManifestHeader
impl ManifestHeader
Sourcepub const CURRENT_DROP_STORE_VERSION: u16 = 1
pub const CURRENT_DROP_STORE_VERSION: u16 = 1
The currently implemented version of each layer. A header that names a future version is parseable structurally but flagged by higher layers (feature-flag policy, spec §18).
pub const CURRENT_METADATA_VERSION: u16 = 1
pub const CURRENT_MANIFEST_VERSION: u16 = 1
pub const fn new( drop_store_version: u16, metadata_version: u16, manifest_version: u16, ) -> Self
pub fn current() -> Self
Sourcepub fn to_bytes(self) -> [u8; 16]
pub fn to_bytes(self) -> [u8; 16]
Serialise to the 16-byte wire form. Inverse of parse_manifest_header.
Trait Implementations§
Source§impl Clone for ManifestHeader
impl Clone for ManifestHeader
Source§fn clone(&self) -> ManifestHeader
fn clone(&self) -> ManifestHeader
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for ManifestHeader
Source§impl Debug for ManifestHeader
impl Debug for ManifestHeader
impl Eq for ManifestHeader
Source§impl PartialEq for ManifestHeader
impl PartialEq for ManifestHeader
impl StructuralPartialEq for ManifestHeader
Auto Trait Implementations§
impl Freeze for ManifestHeader
impl RefUnwindSafe for ManifestHeader
impl Send for ManifestHeader
impl Sync for ManifestHeader
impl Unpin for ManifestHeader
impl UnsafeUnpin for ManifestHeader
impl UnwindSafe for ManifestHeader
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more