pub trait ImmutableFileDigestCacheProvider: Sync + Send {
    // Required methods
    fn store<'life0, 'async_trait>(
        &'life0 self,
        digest_per_filenames: Vec<(ImmutableFileName, HexEncodedDigest)>,
    ) -> Pin<Box<dyn Future<Output = CacheProviderResult<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn get<'life0, 'async_trait>(
        &'life0 self,
        immutables: Vec<ImmutableFile>,
    ) -> Pin<Box<dyn Future<Output = CacheProviderResult<BTreeMap<ImmutableFile, Option<HexEncodedDigest>>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn reset<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = CacheProviderResult<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

A cache provider that store individual ImmutableFile digests.

Required Methods§

source

fn store<'life0, 'async_trait>( &'life0 self, digest_per_filenames: Vec<(ImmutableFileName, HexEncodedDigest)>, ) -> Pin<Box<dyn Future<Output = CacheProviderResult<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Store the given digests

source

fn get<'life0, 'async_trait>( &'life0 self, immutables: Vec<ImmutableFile>, ) -> Pin<Box<dyn Future<Output = CacheProviderResult<BTreeMap<ImmutableFile, Option<HexEncodedDigest>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Associate each given immutable files with a cached value if one exist.

source

fn reset<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = CacheProviderResult<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Reset the stored values

Implementors§