18 writes to CachedResponse
Microsoft.AspNetCore.OutputCaching (3)
OutputCacheContext.cs (1)
78
CachedResponse
= null;
OutputCacheMiddleware.cs (2)
268
context.
CachedResponse
= cacheEntry;
406
context.
CachedResponse
= cacheEntry;
Microsoft.AspNetCore.OutputCaching.Tests (15)
OutputCacheMiddlewareTests.cs (15)
163
context.
CachedResponse
= entry;
177
context.
CachedResponse
= entry;
215
context.
CachedResponse
= entry;
257
context.
CachedResponse
= entry;
278
context.
CachedResponse
= entry;
296
context.
CachedResponse
= entry;
326
context.
CachedResponse
= entry;
342
context.
CachedResponse
= entry;
357
context.
CachedResponse
= entry;
712
context.
CachedResponse
= entry;
741
context.
CachedResponse
= entry;
774
context.
CachedResponse
= entry;
799
context.
CachedResponse
= entry;
871
context.
CachedResponse
= entry;
1074
context.
CachedResponse
= entry;
22 references to CachedResponse
Microsoft.AspNetCore.OutputCaching (10)
OutputCacheContext.cs (1)
77
var tmp =
CachedResponse
;
OutputCacheMiddleware.cs (9)
199
return context.
CachedResponse
;
270
var cacheEntryAge = context.ResponseTime.Value - context.
CachedResponse
.Created;
280
var cachedResponse = context.
CachedResponse
;
311
var body = context.
CachedResponse
.Body;
317
await context.
CachedResponse
.CopyToAsync(response.BodyWriter, context.HttpContext.RequestAborted);
420
&& context.
CachedResponse
is not null)
433
context.
CachedResponse
.SetBody(cachedResponseBody, recycleBuffers: true);
443
await OutputCacheEntryFormatter.StoreAsync(context.CacheKey, context.
CachedResponse
, context.Tags, context.CachedResponseValidFor,
519
var cachedResponse = context.
CachedResponse
;
Microsoft.AspNetCore.OutputCaching.Tests (12)
OutputCacheMiddlewareTests.cs (12)
187
SetDateHeader(context.
CachedResponse
, utcNow - TimeSpan.FromSeconds(10));
192
SetDateHeader(context.
CachedResponse
, utcNow);
197
SetDateHeader(context.
CachedResponse
, utcNow + TimeSpan.FromSeconds(10));
229
SetDateHeaders(context.
CachedResponse
, utcNow + TimeSpan.FromSeconds(10), utcNow - TimeSpan.FromSeconds(10));
234
SetDateHeaders(context.
CachedResponse
, utcNow + TimeSpan.FromSeconds(10), utcNow);
239
SetDateHeaders(context.
CachedResponse
, utcNow - TimeSpan.FromSeconds(10), utcNow + TimeSpan.FromSeconds(10));
282
context.
CachedResponse
.CopyHeadersFrom(new HeaderDictionary { [HeaderNames.LastModified] = HeaderUtilities.FormatDate(utcNow - TimeSpan.FromSeconds(10)) });
343
context.
CachedResponse
.CopyHeadersFrom(new HeaderDictionary { [HeaderNames.ETag] = "\"E2\"" });
358
context.
CachedResponse
.CopyHeadersFrom(new HeaderDictionary { [HeaderNames.ETag] = "\"E2\"" });
676
Assert.Null(context.
CachedResponse
);
680
Assert.NotNull(context.
CachedResponse
);
695
Assert.Equal(new StringValues(new[] { "HeaderB, heaDera" }), context.
CachedResponse
.FindHeader(HeaderNames.Vary));