221 references to EntityTagHeaderValue
FilesWebSite (5)
Controllers\DownloadFilesController.cs (4)
31
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
45
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
93
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
112
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
Controllers\EmbeddedFilesController.cs (1)
40
file.EntityTag = new Microsoft.Net.Http.Headers.
EntityTagHeaderValue
("\"Etag\"");
Microsoft.AspNetCore.Http.Extensions.Tests (1)
HeaderDictionaryTypeExtensionsTest.cs (1)
99
var expected = new
EntityTagHeaderValue
("\"123\"");
Microsoft.AspNetCore.Http.Results.Tests (47)
HttpFileStreamResultTests.cs (1)
66
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
PushStreamResultTests.cs (1)
54
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
src\Shared\ResultsTests\FileContentResultTestBase.cs (16)
58
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
66
new
EntityTagHeaderValue
("\"Etag\""),
97
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
104
new
EntityTagHeaderValue
("\"Etag\""),
136
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
143
new
EntityTagHeaderValue
("\"Etag\""),
146
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"Etag\""));
170
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
177
new
EntityTagHeaderValue
("\"Etag\""),
180
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"NotEtag\""));
207
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
238
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
270
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
277
new
EntityTagHeaderValue
("\"NotEtag\""),
304
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
311
new
EntityTagHeaderValue
("\"Etag\""),
src\Shared\ResultsTests\FileStreamResultTestBase.cs (17)
34
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
44
new
EntityTagHeaderValue
("\"Etag\""),
76
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
85
new
EntityTagHeaderValue
("\"Etag\""),
88
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"Etag\""));
117
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
126
new
EntityTagHeaderValue
("\"Etag\""),
154
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
163
new
EntityTagHeaderValue
("\"Etag\""),
194
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
227
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
261
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
269
new
EntityTagHeaderValue
("\"NotEtag\""),
297
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
305
new
EntityTagHeaderValue
("\"Etag\""),
336
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
347
new
EntityTagHeaderValue
("\"Etag\""),
src\Shared\ResultsTests\PhysicalFileResultTestBase.cs (6)
70
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
77
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"Etag\""));
102
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
109
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"Etag\""));
129
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
136
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"NotEtag\""));
src\Shared\ResultsTests\VirtualFileResultTestBase.cs (6)
91
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
95
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"Etag\""));
128
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
132
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"Etag\""));
161
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
165
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"NotEtag\""));
Microsoft.AspNetCore.Mvc.Core.Test (59)
ControllerBaseTest.cs (6)
1709
var entityTag = (entityTagString == null) ? null : new
EntityTagHeaderValue
(entityTagString);
1753
var entityTag = (entityTagString == null) ? null : new
EntityTagHeaderValue
(entityTagString);
1797
var entityTag = (entityTagString == null) ? null : new
EntityTagHeaderValue
(entityTagString);
1841
var entityTag = (entityTagString == null) ? null : new
EntityTagHeaderValue
(entityTagString);
1895
var entityTag = (entityTagString == null) ? null : new
EntityTagHeaderValue
(entityTagString);
1947
var entityTag = (entityTagString == null) ? null : new
EntityTagHeaderValue
(entityTagString);
FileResultHelperTest.cs (7)
252
var etag = new
EntityTagHeaderValue
("\"Etag\"");
255
new
EntityTagHeaderValue
(ifMatch),
292
var etag = new
EntityTagHeaderValue
("\"Etag\"");
295
new
EntityTagHeaderValue
(ifMatch),
330
var etag = new
EntityTagHeaderValue
("\"Etag\"");
333
new
EntityTagHeaderValue
(ifMatch),
366
var etag = new
EntityTagHeaderValue
("\"Etag\"");
FileStreamResultTest.cs (1)
77
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
src\Shared\ResultsTests\FileContentResultTestBase.cs (16)
58
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
66
new
EntityTagHeaderValue
("\"Etag\""),
97
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
104
new
EntityTagHeaderValue
("\"Etag\""),
136
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
143
new
EntityTagHeaderValue
("\"Etag\""),
146
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"Etag\""));
170
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
177
new
EntityTagHeaderValue
("\"Etag\""),
180
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"NotEtag\""));
207
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
238
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
270
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
277
new
EntityTagHeaderValue
("\"NotEtag\""),
304
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
311
new
EntityTagHeaderValue
("\"Etag\""),
src\Shared\ResultsTests\FileStreamResultTestBase.cs (17)
34
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
44
new
EntityTagHeaderValue
("\"Etag\""),
76
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
85
new
EntityTagHeaderValue
("\"Etag\""),
88
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"Etag\""));
117
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
126
new
EntityTagHeaderValue
("\"Etag\""),
154
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
163
new
EntityTagHeaderValue
("\"Etag\""),
194
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
227
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
261
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
269
new
EntityTagHeaderValue
("\"NotEtag\""),
297
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
305
new
EntityTagHeaderValue
("\"Etag\""),
336
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
347
new
EntityTagHeaderValue
("\"Etag\""),
src\Shared\ResultsTests\PhysicalFileResultTestBase.cs (6)
70
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
77
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"Etag\""));
102
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
109
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"Etag\""));
129
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
136
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"NotEtag\""));
src\Shared\ResultsTests\VirtualFileResultTestBase.cs (6)
91
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
95
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"Etag\""));
128
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
132
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"Etag\""));
161
var entityTag = new
EntityTagHeaderValue
("\"Etag\"");
165
requestHeaders.IfRange = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"NotEtag\""));
Microsoft.AspNetCore.OutputCaching.Tests (7)
OutputCacheMiddlewareTests.cs (4)
309
{ new
EntityTagHeaderValue
("\"tag\""), new
EntityTagHeaderValue
("\"tag\"") },
310
{ new EntityTagHeaderValue("\"tag\"", true), new
EntityTagHeaderValue
("\"tag\"") },
311
{ new
EntityTagHeaderValue
("\"tag\""), new EntityTagHeaderValue("\"tag\"", true) },
OutputCacheTests.cs (3)
697
context.Response.GetTypedHeaders().ETag = new
EntityTagHeaderValue
("\"E1\"");
746
context.Response.GetTypedHeaders().ETag = new
EntityTagHeaderValue
("\"E1\"");
772
var builders = TestUtils.CreateBuildersWithOutputCaching(contextAction: context => context.Response.GetTypedHeaders().ETag = new
EntityTagHeaderValue
("\"E1\""));
Microsoft.AspNetCore.ResponseCaching.Tests (7)
ResponseCachingMiddlewareTests.cs (4)
306
{ new
EntityTagHeaderValue
("\"tag\""), new
EntityTagHeaderValue
("\"tag\"") },
307
{ new EntityTagHeaderValue("\"tag\"", true), new
EntityTagHeaderValue
("\"tag\"") },
308
{ new
EntityTagHeaderValue
("\"tag\""), new EntityTagHeaderValue("\"tag\"", true) },
ResponseCachingTests.cs (3)
643
context.Response.GetTypedHeaders().ETag = new
EntityTagHeaderValue
("\"E1\"");
696
context.Response.GetTypedHeaders().ETag = new
EntityTagHeaderValue
("\"E1\"");
724
var builders = TestUtils.CreateBuildersWithResponseCaching(contextAction: context => context.Response.GetTypedHeaders().ETag = new
EntityTagHeaderValue
("\"E1\""));
Microsoft.AspNetCore.StaticFiles (1)
StaticFileContext.cs (1)
127
_etag = new
EntityTagHeaderValue
('\"' + Convert.ToString(etagHash, 16) + '\"');
Microsoft.Net.Http.Headers (1)
RangeConditionHeaderValue.cs (1)
51
: this(new
EntityTagHeaderValue
(entityTag))
Microsoft.Net.Http.Headers.Tests (93)
EntityTagHeaderValueTest.cs (85)
11
Assert.Throws<ArgumentException>(() => new
EntityTagHeaderValue
(null));
13
Assert.Throws<ArgumentException>(() => new
EntityTagHeaderValue
(string.Empty));
34
var etag = new
EntityTagHeaderValue
("\"tag\"");
50
var etag = new
EntityTagHeaderValue
("\"e tag\"");
63
var etag1 = new
EntityTagHeaderValue
("\"tag\"");
64
var etag2 = new
EntityTagHeaderValue
("\"TAG\"");
66
var etag4 = new
EntityTagHeaderValue
("\"tag1\"");
67
var etag5 = new
EntityTagHeaderValue
("\"tag\"");
80
var etag1 = new
EntityTagHeaderValue
("\"tag\"");
81
var etag2 = new
EntityTagHeaderValue
("\"TAG\"");
83
var etag4 = new
EntityTagHeaderValue
("\"tag1\"");
84
var etag5 = new
EntityTagHeaderValue
("\"tag\"");
110
{ new
EntityTagHeaderValue
("\"tag\""), new
EntityTagHeaderValue
("\"TAG\"") },
112
{ new
EntityTagHeaderValue
("\"tag\""), new EntityTagHeaderValue("\"tag\"", true) },
113
{ new
EntityTagHeaderValue
("\"tag\""), new
EntityTagHeaderValue
("\"tag1\"") },
114
{ new
EntityTagHeaderValue
("\"tag\""), EntityTagHeaderValue.Any },
133
{ new
EntityTagHeaderValue
("\"tag\""), new
EntityTagHeaderValue
("\"tag\"") },
152
{ new
EntityTagHeaderValue
("\"tag\""), new
EntityTagHeaderValue
("\"TAG\"") },
153
{ new
EntityTagHeaderValue
("\"tag\""), new
EntityTagHeaderValue
("\"tag1\"") },
154
{ new
EntityTagHeaderValue
("\"tag\""), EntityTagHeaderValue.Any },
173
{ new
EntityTagHeaderValue
("\"tag\""), new
EntityTagHeaderValue
("\"tag\"") },
175
{ new
EntityTagHeaderValue
("\"tag\""), new EntityTagHeaderValue("\"tag\"", true) },
191
CheckValidParse("\"tag\"", new
EntityTagHeaderValue
("\"tag\""));
192
CheckValidParse(" \"tag\" ", new
EntityTagHeaderValue
("\"tag\""));
193
CheckValidParse("\r\n \"tag\"\r\n ", new
EntityTagHeaderValue
("\"tag\""));
194
CheckValidParse("\"tag\"", new
EntityTagHeaderValue
("\"tag\""));
195
CheckValidParse("\"tag会\"", new
EntityTagHeaderValue
("\"tag会\""));
197
CheckValidParse("*", new
EntityTagHeaderValue
("*"));
220
CheckValidTryParse("\"tag\"", new
EntityTagHeaderValue
("\"tag\""));
221
CheckValidTryParse(" \"tag\" ", new
EntityTagHeaderValue
("\"tag\""));
222
CheckValidTryParse("\r\n \"tag\"\r\n ", new
EntityTagHeaderValue
("\"tag\""));
223
CheckValidTryParse("\"tag\"", new
EntityTagHeaderValue
("\"tag\""));
224
CheckValidTryParse("\"tag会\"", new
EntityTagHeaderValue
("\"tag会\""));
226
CheckValidTryParse("*", new
EntityTagHeaderValue
("*"));
286
new
EntityTagHeaderValue
("\"tag\""),
287
new
EntityTagHeaderValue
("\"tag\""),
288
new
EntityTagHeaderValue
("\"tag\""),
289
new
EntityTagHeaderValue
("\"tag会\""),
290
new
EntityTagHeaderValue
("\"tag\""),
291
new
EntityTagHeaderValue
("\"tag\""),
292
new
EntityTagHeaderValue
("\"tag\""),
293
new
EntityTagHeaderValue
("\"tag\""),
319
new
EntityTagHeaderValue
("\"tag\""),
320
new
EntityTagHeaderValue
("\"tag\""),
321
new
EntityTagHeaderValue
("\"tag\""),
322
new
EntityTagHeaderValue
("\"tag会\""),
323
new
EntityTagHeaderValue
("\"tag\""),
324
new
EntityTagHeaderValue
("\"tag\""),
325
new
EntityTagHeaderValue
("\"tag\""),
326
new
EntityTagHeaderValue
("\"tag\""),
351
new
EntityTagHeaderValue
("\"tag\""),
352
new
EntityTagHeaderValue
("\"tag\""),
353
new
EntityTagHeaderValue
("\"tag\""),
354
new
EntityTagHeaderValue
("\"tag会\""),
355
new
EntityTagHeaderValue
("\"tag\""),
356
new
EntityTagHeaderValue
("\"tag\""),
357
new
EntityTagHeaderValue
("\"tag\""),
358
new
EntityTagHeaderValue
("\"tag\""),
383
new
EntityTagHeaderValue
("\"tag\""),
384
new
EntityTagHeaderValue
("\"tag\""),
385
new
EntityTagHeaderValue
("\"tag\""),
386
new
EntityTagHeaderValue
("\"tag会\""),
387
new
EntityTagHeaderValue
("\"tag\""),
388
new
EntityTagHeaderValue
("\"tag\""),
389
new
EntityTagHeaderValue
("\"tag\""),
390
new
EntityTagHeaderValue
("\"tag\""),
415
new
EntityTagHeaderValue
("\"tag\""),
416
new
EntityTagHeaderValue
("\"tag\""),
417
new
EntityTagHeaderValue
("\"tag\""),
418
new
EntityTagHeaderValue
("\"tag会\""),
419
new
EntityTagHeaderValue
("\"tag\""),
420
new
EntityTagHeaderValue
("\"tag\""),
463
new
EntityTagHeaderValue
("\"tag\""),
464
new
EntityTagHeaderValue
("\"tag\""),
465
new
EntityTagHeaderValue
("\"tag\""),
466
new
EntityTagHeaderValue
("\"tag会\""),
467
new
EntityTagHeaderValue
("\"tag\""),
468
new
EntityTagHeaderValue
("\"tag\""),
518
Assert.Throws<FormatException>(() => new
EntityTagHeaderValue
(tag));
RangeConditionHeaderValueTest.cs (8)
11
var rangeCondition = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"x\""));
12
Assert.Equal(new
EntityTagHeaderValue
("\"x\""), rangeCondition.EntityTag);
23
Assert.Equal(new
EntityTagHeaderValue
("\"y\""), rangeCondition.EntityTag);
41
var rangeCondition = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"x\""));
52
var rangeCondition2 = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"x\""));
73
var rangeCondition2 = new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"x\""));
102
CheckValidParse("\"tag\"", new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"tag\"")));
131
CheckValidTryParse("\"tag\"", new RangeConditionHeaderValue(new
EntityTagHeaderValue
("\"tag\"")));