Skip to main content

Module startup_library_snapshot

Module startup_library_snapshot 

Source
Expand description

Compact on-disk snapshot of library metadata (platforms + merged collections).

Used by the TUI to paint the library screen immediately on entry while a background refresh reconciles with the API. Full ROM lists remain on-demand and continue to use crate::core::cache::RomCache.

Structs§

CollectionDigestEntry
Compact digest used to quickly detect collection-summary changes.
LibraryMetadataFetch
Result of a live metadata fetch (background or cold path).

Functions§

build_collection_digest_from_collections
Build a lightweight digest keyed by collection identity (manual/smart/virtual).
fetch_collection_summaries
Stage-A refresh: collections summary only (manual/smart/virtual merge).
fetch_merged_library_metadata
Fetch platforms and merged collections from the API (same behavior as the former synchronous TUI main-menu path, including virtual collection timeout).
load_snapshot
Load a snapshot from disk if present and valid.
save_snapshot
Persist merged metadata for next startup.
snapshot_effective_path
Effective path to the snapshot file.