public IAsyncResult BeginPersist(CacheRequest request, CacheResponse response, AsyncCallback callback, object state) { CacheAsyncResult cacheAsyncResult = new CacheAsyncResult(); if (!this.cache.ContainsKey(request.CanonicalUri.ToString()) && !request.CanonicalUri.ToString().ToUpperInvariant().EndsWith(".ISML/MANIFEST") && !request.CanonicalUri.ToString().ToUpperInvariant().EndsWith(".ISM/MANIFEST")) { cacheAsyncResult.FragmentUrl = request.CanonicalUri.ToString(); cacheAsyncResult.Complete(response, true); return(cacheAsyncResult); } cacheAsyncResult.Complete(null, true); return(cacheAsyncResult); }
public IAsyncResult BeginRetrieve(CacheRequest request, AsyncCallback callback, object state) { CacheResponse response = null; CacheAsyncResult cacheAsyncResult = new CacheAsyncResult { FragmentUrl = request.CanonicalUri.ToString() }; cacheAsyncResult.Complete(response, true); return(cacheAsyncResult); }