public IAsyncLoadingCache <K, V> BuildAsync(AsyncCacheLoader <K, V> loader) { RequireWeightWithWeigher(); if (IsWeakValues) { throw new InvalidOperationException("Weak values cannot be combined with AsyncLoadingCache."); } if (loader == null) { throw new ArgumentNullException("loader", "loader cannot be null."); } // TODO: implement this.. //return (IsBounded || DoesRefreshAfterWrite) ? new BoundAsyncLoadingCache<K, V>(this, loader) : new UnboundedAsyncLoadingCache<K, V>(this, loader); throw new NotImplementedException(); }
public UnboundedAsyncLoadingCache(Caffeine <K, Task <V> > builder, AsyncCacheLoader <K, V> loader) : base(new UnboundedLocalCache <K, Task <V> >(builder, true), loader) { }
internal LocalAsyncLoadingCache(C cache, AsyncCacheLoader <K, V> loader) { this.mLoader = loader; //this.canBulkLoad = canBulkLoad(loader); this.cache = cache; }