18 writes to CachedResponse
Microsoft.AspNetCore.OutputCaching (3)
OutputCacheContext.cs (1)
78
CachedResponse
= null;
OutputCacheMiddleware.cs (2)
260
context.
CachedResponse
= cacheEntry;
405
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;
616
context.
CachedResponse
= entry;
645
context.
CachedResponse
= entry;
678
context.
CachedResponse
= entry;
703
context.
CachedResponse
= entry;
775
context.
CachedResponse
= entry;
979
context.
CachedResponse
= entry;
22 references to CachedResponse
Microsoft.AspNetCore.OutputCaching (10)
OutputCacheContext.cs (1)
77
var tmp =
CachedResponse
;
OutputCacheMiddleware.cs (9)
192
return context.
CachedResponse
;
262
var cacheEntryAge = context.ResponseTime.Value - context.
CachedResponse
.Created;
279
var cachedResponse = context.
CachedResponse
;
310
var body = context.
CachedResponse
.Body;
316
await context.
CachedResponse
.CopyToAsync(response.BodyWriter, context.HttpContext.RequestAborted);
419
&& context.
CachedResponse
is not null)
432
context.
CachedResponse
.SetBody(cachedResponseBody, recycleBuffers: true);
442
await OutputCacheEntryFormatter.StoreAsync(context.CacheKey, context.
CachedResponse
, context.Tags, context.CachedResponseValidFor,
518
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\"" });
580
Assert.Null(context.
CachedResponse
);
584
Assert.NotNull(context.
CachedResponse
);
599
Assert.Equal(new StringValues(new[] { "HeaderB, heaDera" }), context.
CachedResponse
.FindHeader(HeaderNames.Vary));