pub struct LabelIndexSignal {
pub present: bool,
pub bytes: u64,
pub entries: Option<u64>,
}Expand description
The file’s label-prefix-search affordance: does it carry a LABEL_INDEX section (kind 8), how many labels, and how large is it?
Measured at read time, never stored, for the reasons
TextIndexSignal gives: presence and size come free with the header,
and entries is the u64 at bytes 20..28 of the section’s fixed preamble —
one 32-byte range read, never the index. A file without the section may
still answer a prefix search from the legacy label block of its
pyramid-meta (at most 8,192 labels); that block is not measured here,
because reading it means fetching the whole pyramid-meta.
Fields§
§present: boolTrue iff the file has a kind-8 section. Always written, including as
false.
bytes: u64Byte length of the whole LABEL_INDEX section.
entries: Option<u64>Number of (subject, label) entries; None when there is no index or
its preamble was unreadable.
Implementations§
Source§impl LabelIndexSignal
impl LabelIndexSignal
Trait Implementations§
Source§impl Clone for LabelIndexSignal
impl Clone for LabelIndexSignal
impl Copy for LabelIndexSignal
Source§impl Debug for LabelIndexSignal
impl Debug for LabelIndexSignal
Source§impl Default for LabelIndexSignal
impl Default for LabelIndexSignal
Source§impl<'de> Deserialize<'de> for LabelIndexSignal
impl<'de> Deserialize<'de> for LabelIndexSignal
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for LabelIndexSignal
Source§impl PartialEq for LabelIndexSignal
impl PartialEq for LabelIndexSignal
Source§impl Serialize for LabelIndexSignal
impl Serialize for LabelIndexSignal
impl StructuralPartialEq for LabelIndexSignal
Auto Trait Implementations§
impl Freeze for LabelIndexSignal
impl RefUnwindSafe for LabelIndexSignal
impl Send for LabelIndexSignal
impl Sync for LabelIndexSignal
impl Unpin for LabelIndexSignal
impl UnsafeUnpin for LabelIndexSignal
impl UnwindSafe for LabelIndexSignal
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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> ⓘ
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> ⓘ
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