Skip to main content

hashtree_cli/socialgraph/
snapshot.rs

1use anyhow::Result;
2use bytes::Bytes;
3pub use nostr_social_graph::BinaryBudget as SnapshotOptions;
4
5use super::SocialGraphBackend;
6
7pub fn build_snapshot_chunks(
8    store: &(impl SocialGraphBackend + ?Sized),
9    root: &[u8; 32],
10    options: &SnapshotOptions,
11) -> Result<Vec<Bytes>> {
12    store.snapshot_chunks(root, options)
13}