Struct AssetManifestEntry
pub struct AssetManifestEntry<'a> {
pub path: &'a str,
pub byte_len: usize,
pub fingerprint: u64,
}Expand description
Read-only metadata for one asset, produced by Bundle::manifest.
The path borrows the bundle; the other fields are values. No payload is copied or retained. Changing a returned entry cannot change the bundle.
use ferravex_engine::assets::{AssetManifestEntry, Bundle};
let mut bundle = Bundle::default();
bundle.insert("meta/title", b"hello")?;
let entry: AssetManifestEntry<'_> = bundle.manifest().next().unwrap();
assert_eq!(entry.path, "meta/title");
assert_eq!(entry.byte_len, 5);
assert_eq!(entry.fingerprint, 0xa430d84680aabd0b);Fields§
§path: &'a strCanonical relative ASCII path with / separators and case preserved.
byte_len: usizeDecoded content length in bytes, including zero for an empty asset.
fingerprint: u64Stable 64-bit FNV-1a of decoded bytes only, matching the FXPK0001 content
checksum: start at 0xcbf29ce484222325, then XOR each byte and multiply
by 0x100000001b3 modulo 2^64. Independent of path, compression, insertion
order, platform byte order and reload generation. This is a diagnostic
fingerprint, not authentication or proof of equality; collisions are
possible. Bundle diffs and no-op detection still compare exact content.
Trait Implementations§
§impl<'a> Clone for AssetManifestEntry<'a>
impl<'a> Clone for AssetManifestEntry<'a>
§fn clone(&self) -> AssetManifestEntry<'a>
fn clone(&self) -> AssetManifestEntry<'a>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more