pub async fn write_hash_with_algo<P, D>(
algo: Algorithm,
cache: P,
data: D,
) -> Result<Integrity>Expand description
Writes data to the cache, skipping associating an index key with it.
Use this to customize the hashing algorithm.
ยงExample
use async_attributes;
#[async_attributes::main]
async fn main() -> cacache::Result<()> {
cacache::write_hash_with_algo(cacache::Algorithm::Xxh3, "./my-cache", b"hello").await?;
Ok(())
}