pub struct Manifest {
pub version: u8,
pub bundles: Vec<ManifestRow>,
}Expand description
The manifest, manifest: every sealed bundle’s row, in order. JSON,
rewritten whole on every change.
Fields§
§version: u8Format version, 1.
bundles: Vec<ManifestRow>One row per sealed bundle, by index.
Implementations§
Source§impl Manifest
impl Manifest
Sourcepub fn read(store: &impl TileStore) -> Result<Self>
pub fn read(store: &impl TileStore) -> Result<Self>
The manifest the store holds; empty for a store without one.
Sourcepub fn write(&self, store: &impl TileStore) -> Result<()>
pub fn write(&self, store: &impl TileStore) -> Result<()>
Writes the manifest, whole or not at all.
Sourcepub fn row(index: u64, sidecar: &Sidecar, bytes: &[u8]) -> ManifestRow
pub fn row(index: u64, sidecar: &Sidecar, bytes: &[u8]) -> ManifestRow
The row for bundle index built from its sidecar bytes.
Sourcepub fn candidates<'a>(
&'a self,
key: &[u8],
) -> impl Iterator<Item = &'a ManifestRow> + 'a
pub fn candidates<'a>( &'a self, key: &[u8], ) -> impl Iterator<Item = &'a ManifestRow> + 'a
Rows whose key range holds key.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Manifest
impl<'de> Deserialize<'de> for Manifest
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>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Manifest
impl StructuralPartialEq for Manifest
Auto Trait Implementations§
impl Freeze for Manifest
impl RefUnwindSafe for Manifest
impl Send for Manifest
impl Sync for Manifest
impl Unpin for Manifest
impl UnsafeUnpin for Manifest
impl UnwindSafe for Manifest
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