pub fn read<P, K>(cache: P, key: K) -> Result<Vec<u8>>Expand description
Reads the entire contents of a cache file synchronously into a bytes vector, looking the data up by key.
ยงExample
use std::io::Read;
fn main() -> cacache_sync::Result<()> {
let data = cacache_sync::read("./my-cache", "my-key")?;
Ok(())
}