Implemented interface member:
152 writes to
BasicWebSite (7)
Controllers\AntiforgeryController.cs (2)
23
ViewData
[
"ReturnUrl"] = returnUrl;
57
ViewData
[
"ReturnUrl"] = returnUrl;
Controllers\HomeController.cs (1)
95
ViewData
[
"naming"] = snakeCase ? (NamingStrategy)new SnakeCaseNamingStrategy() : new DefaultNamingStrategy();
Controllers\PageRouteController.cs (2)
32
ViewData
[
"page"] = page;
39
ViewData
[
"page"] = page;
Controllers\TempDataPropertyController.cs (2)
35
ViewData
[
"Message"] = Message;
36
ViewData
[
"NullableInt"] = NullableInt;
ClaimsTransformation (2)
Controllers\AccountController.cs (2)
18
ViewData
[
"ReturnUrl"] = returnUrl;
31
ViewData
[
"ReturnUrl"] = returnUrl;
Cookies (2)
Controllers\AccountController.cs (2)
17
ViewData
[
"ReturnUrl"] = returnUrl;
30
ViewData
[
"ReturnUrl"] = returnUrl;
CustomPolicyProvider (1)
Controllers\AccountController.cs (1)
16
ViewData
[
"ReturnUrl"] = returnUrl;
HtmlGenerationWebSite (17)
Controllers\Catalog_CacheTagHelperController.cs (12)
16
ViewData
[
"Category"] = category;
17
ViewData
[
"Locale"] = locale;
18
ViewData
[
"CorrelationId"] = correlationId;
26
ViewData
[
"ProductId"] = id;
33
ViewData
[
"CorrelationId"] = correlationId;
40
ViewData
[
"Message"] = "Welcome Guest. Your confirmation id is " + confirmationId;
41
ViewData
[
"Region"] = region;
49
ViewData
[
"Message"] = message;
50
ViewData
[
"Region"] = region;
62
ViewData
[
"CorrelationId"] = correlationId;
69
ViewData
[
"Category"] = category;
70
ViewData
[
"CorrelationId"] = correlationId;
Controllers\HtmlGeneration_HomeController.cs (5)
66
ViewData
[
"Items"] = _productsListWithSelection;
73
ViewData
[
"Items"] = _productsListWithSelection;
147
ViewData
[
nameof(Employee.Gender)] = "Gender value that will not match.";
148
ViewData
[
nameof(Employee.Name)] = "Name value that should not be seen.";
155
ViewData
[
"Items"] = _productsList;
IdentitySample.Mvc (10)
Controllers\AccountController.cs (7)
44
ViewData
[
"ReturnUrl"] = returnUrl;
55
ViewData
[
"ReturnUrl"] = returnUrl;
92
ViewData
[
"ReturnUrl"] = returnUrl;
103
ViewData
[
"ReturnUrl"] = returnUrl;
189
ViewData
[
"ReturnUrl"] = returnUrl;
190
ViewData
[
"ProviderDisplayName"] = info.ProviderDisplayName;
230
ViewData
[
"ReturnUrl"] = returnUrl;
Controllers\ManageController.cs (3)
41
ViewData
[
"StatusMessage"] =
296
ViewData
[
"StatusMessage"] =
309
ViewData
[
"ShowRemoveButton"] = user.PasswordHash != null || userLogins.Count > 1;
Microsoft.AspNetCore.Identity.UI (1)
Areas\Identity\Filters\ExternalLoginsPageFilter.cs (1)
22
page.ViewData
[
"ManageNav.HasExternalLogins"] = hasExternalLogins;
Microsoft.AspNetCore.Mvc.RazorPages (1)
Filters\PageViewDataAttributeFilter.cs (1)
43
viewData
[
property.Key] = value;
Microsoft.AspNetCore.Mvc.TagHelpers.Test (3)
PartialTagHelperTest.cs (3)
235
viewContext.ViewData
[
"key"] = expected;
277
viewData
[
"key"] = expected;
279
viewContext.ViewData
[
"key"] = "ViewContext";
Microsoft.AspNetCore.Mvc.ViewFeatures (3)
DynamicViewData.cs (1)
61
ViewData
[
binder.Name] = value;
Filters\ControllerViewDataAttributeFilter.cs (1)
38
viewData
[
property.Key] = value;
TemplateBuilder.cs (1)
126
viewData
[
kvp.Key] = kvp.Value;
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (83)
DefaultDisplayTemplatesTest.cs (4)
267
helper.ViewData
[
"Property1"] = "ViewData string";
289
helper.ViewData
[
"Property1"] = "ViewData string";
334
helper.ViewData
[
"Property1"] = "ViewData string";
363
helper.ViewData
[
"Property1"] = "ViewData string";
DefaultEditorTemplatesTest.cs (9)
536
viewData
[
"FieldPrefix"] = "ViewData string";
557
viewData
[
"htmlAttributes"] = new { @class = "super", value = "Html attributes string" };
583
helper.ViewData
[
"Property1"] = "True";
658
helper.ViewData
[
"Property1"] = "True";
743
helper.ViewData
[
"Property1"] = "True";
814
helper.ViewData
[
"Property1"] = "ViewData string";
1231
helper.ViewData
[
"Property1"] = "ViewData string";
1280
helper.ViewData
[
"Property1"] = "ViewData string";
1311
helper.ViewData
[
"Property1"] = "ViewData string";
DefaultHtmlGeneratorTest.cs (8)
499
viewContext.ViewData
[
nameof(Model.Name)] = Enumerable.Empty<SelectListItem>();
522
viewContext.ViewData
[
nameof(Model.Name)] = value;
589
viewContext.ViewData
[
nameof(Model.Name)] = "ignored ViewData value";
617
viewContext.ViewData
[
nameof(Model.Name)] = "ignored ViewData value";
665
viewContext.ViewData
[
nameof(Model.Name)] = "ignored ViewData value";
693
viewContext.ViewData
[
nameof(Model.Name)] = rawValue;
771
viewContext.ViewData
[
nameof(Model.Collection)] = new[] { "ignored ViewData value" };
800
viewContext.ViewData
[
nameof(Model.Collection)] = rawValue;
ExpressionMetadataProviderTest.cs (1)
144
viewData
[
"Object"] = myModel;
Rendering\HtmlHelperCheckboxTest.cs (3)
305
helper.ViewData
[
"Prefix.Property1"] = true;
327
helper.ViewData
[
"Prefix"] = new TestModel { Property1 = true };
348
helper.ViewData
[
"Prefix"] = new TestModel { Property1 = true };
Rendering\HtmlHelperDisplayNameExtensionsTest.cs (1)
60
helper.ViewData
[
"value"] = "testvalue";
Rendering\HtmlHelperDisplayTextTest.cs (4)
222
helper.ViewData
[
"Name"] = "View data dictionary value";
240
helper.ViewData
[
"Name"] = "View data dictionary value";
259
viewData
[
"FieldPrefix.Name"] = "View data dictionary value";
284
viewData
[
"Name"] = "View data dictionary value";
Rendering\HtmlHelperDropDownListExtensionsTest.cs (5)
34
helper.ViewData
[
"Property1"] = BasicSelectList;
58
helper.ViewData
[
"Property1"] = BasicSelectList;
109
helper.ViewData
[
"Property1"] = BasicSelectList;
157
helper.ViewData
[
"Property1"] = BasicSelectList;
183
helper.ViewData
[
"Property1"] = BasicSelectList;
Rendering\HtmlHelperHiddenTest.cs (14)
84
helper.ViewData
[
"Prefix"] = new HiddenModel { Property1 = "contained-view-data-value" };
102
helper.ViewData
[
"Prefix"] = new HiddenModel { Property1 = "contained-view-data-value" };
119
helper.ViewData
[
"Property1"] = null;
137
helper.ViewData
[
"Prefix.Property1"] = null;
530
viewData
[
"Property3[height]"] = "Prop3Value";
531
viewData
[
"Property4.Property5"] = "Prop5Value";
532
viewData
[
"Property4.Property6[0]"] = "Prop6Value";
569
viewData
[
"Property3[height]"] = "Prop3Value";
570
viewData
[
"Property4.Property5"] = "Prop5Value";
571
viewData
[
"Property4.Property6[0]"] = "Prop6Value";
801
viewData
[
"Property3[key]"] = "Prop3Val";
802
viewData
[
"Property4.Property5"] = "Prop4Val";
803
viewData
[
"Property4.Property6[0]"] = "Prop6Val";
963
viewData
[
"Property1"] = "view-data-val";
Rendering\HtmlHelperLabelExtensionsTest.cs (1)
139
helper.ViewData
[
"value"] = "testvalue";
Rendering\HtmlHelperListBoxExtensionsTest.cs (4)
34
helper.ViewData
[
"Property1"] = BasicSelectList;
84
helper.ViewData
[
"Property2"] = new List<string> { "1", "2", "5" };
106
helper.ViewData
[
"Property1"] = BasicSelectList;
156
helper.ViewData
[
"Property3"] = new List<string> { "0", "2" };
Rendering\HtmlHelperPasswordTest.cs (6)
359
viewData
[
"pre.Property3[key]"] = "vdd-value1";
360
viewData
[
"pre.Property4.Property5"] = "vdd-value2";
361
viewData
[
"pre.Property4.Property6[0]"] = "vdd-value3";
511
helper.ViewData
[
"pre.Property3[key]"] = "VDProp3Val";
512
helper.ViewData
[
"pre.Property4.Property5"] = "VDProp5Val";
513
helper.ViewData
[
"pre.Property4.Property6"] = "VDProp6Val";
Rendering\HtmlHelperSelectTest.cs (3)
354
helper.ViewData
[
"Property1"] = selectList;
623
helper.ViewData
[
"Property1"] = selectList;
672
helper.ViewData
[
"Property1"] = selectList;
Rendering\HtmlHelperValueTest.cs (8)
35
helper.ViewData
[
"Prefix.StringProperty"] = "PrefixedViewDataValue";
50
helper.ViewData
[
"Prefix"] = new { StringProperty = "ContainedViewDataValue" };
64
helper.ViewData
[
"Prefix"] = new { StringProperty = "ContainedViewDataValue" };
108
helper.ViewData
[
"StringProperty"] = null;
122
helper.ViewData
[
"Prefix.StringProperty"] = null;
160
viewData
[
"StringProperty"] = "ViewDataValue";
218
viewData
[
"StringProperty"] = "ViewDataValue <\"\">";
257
helper.ViewData
[
"StringProperty"] = "ViewDataValue";
ViewComponentTests.cs (2)
40
viewComponent.ViewData
[
"A"] = "Alice";
41
viewComponent.ViewData
[
"B"] = "Bob";
ViewDataDictionaryOfTModelTest.cs (3)
39
source
[
"foo"] = "bar";
78
source
[
"foo"] = "bar";
159
source
[
"key1"] = "value1";
ViewDataDictionaryTest.cs (7)
194
source
[
"foo"] = "bar";
735
viewData
[
"foo"] = "value";
749
viewData
[
"foo"] = "value";
769
viewData
[
"Title"] = "Home Page";
770
viewData
[
"Message"] = "Welcome to ASP.NET MVC!";
790
viewData
[
"Title"] = "Home Page";
791
viewData
[
"Message"] = "Welcome to ASP.NET MVC!";
PathSchemeSelection (2)
Controllers\AccountController.cs (2)
18
ViewData
[
"ReturnUrl"] = returnUrl;
31
ViewData
[
"ReturnUrl"] = returnUrl;
RazorPagesWebSite (2)
Pages\CustomModelTypeModel.cshtml.cs (1)
70
ViewData
[
"UserType"] = typeof(TUser).Name;
Pages\ViewDataAvailableAfterHandlerExecuted.cshtml.cs (1)
26
pageResult.ViewData
[
"Foo"] = "Bar";
RazorWebSite (11)
Components\ComponentWithLayout.cs (1)
12
ViewData
[
"Title"] = "ViewComponent With Title";
Components\ComponentWithViewStart.cs (1)
12
ViewData
[
"Title"] = "ViewComponent With ViewStart";
Controllers\AddTagHelperComponentController.cs (1)
21
ViewData
[
"TestData"] = "Value";
Controllers\PartialViewEngineController.cs (1)
32
ViewData
[
"data-from-controller"] = "hello from controller";
Controllers\ViewEngineController.cs (4)
37
ViewData
[
"TestKey"] = "test-value";
59
ViewData
[
"Title"] = "Controller title";
65
ViewData
[
"data-from-controller"] = "hello from controller";
71
ViewData
[
"Title"] = "View With Component With Layout";
Controllers\ViewNameSpecification_HomeController.cs (2)
52
ViewData
[
"Layout"] = "_NonSharedLayout.cshtml";
58
ViewData
[
"Layout"] = "~/Views/ViewNameSpecification_Home/_NonSharedLayout.cshtml";
Services\TestBodyTagHelperComponent.cs (1)
40
ViewContext.ViewData
[
"TestData"] = "NewValue";
StaticFilesAuth (2)
Controllers\AccountController.cs (2)
17
ViewData
[
"ReturnUrl"] = returnUrl;
30
ViewData
[
"ReturnUrl"] = returnUrl;
TagHelpersWebSite (5)
Controllers\EncodersController.cs (5)
12
ViewData
[
"Title"] = "Using the default HTML encoder";
18
ViewData
[
"Title"] = "Using a custom HTML encoder";
24
ViewData
[
"Title"] = "Using the null HTML encoder";
32
ViewData
[
"Title"] = "Using two HTML encoders";
40
ViewData
[
"Title"] = "Using three HTML encoders";
35 references to
HtmlGenerationWebSite (1)
Components\SplashViewComponent.cs (1)
12
var region = (string)ViewData
[
"Locale"];
Identity.ExternalClaims (1)
Pages\Account\Manage\ManageNavPages.cs (1)
32
var activePage = viewContext.ViewData
[
"ActivePage"] as string
Microsoft.AspNetCore.Identity.UI (4)
Areas\Identity\Pages\V4\Account\Manage\ManageNavPages.cs (2)
116
var activePage = viewContext.ViewData
[
"ActivePage"] as string
175
var activePage = viewContext.ViewData
[
"ActivePage"] as string
Areas\Identity\Pages\V5\Account\Manage\ManageNavPages.cs (2)
116
var activePage = viewContext.ViewData
[
"ActivePage"] as string
175
var activePage = viewContext.ViewData
[
"ActivePage"] as string
Microsoft.AspNetCore.Mvc.Razor.Test (6)
Compilation\RazorPagePropertyActivatorTest.cs (4)
76
Assert.Equal("test-value", viewDataDictionary
[
"test-key"]);
105
Assert.Equal("test-value", viewDataDictionary
[
"test-key"]);
134
Assert.Equal("test-value", viewDataDictionary
[
"test-key"]);
163
Assert.Equal("test-value", viewDataDictionary
[
"test-key"]);
RazorPageActivatorTest.cs (2)
137
Assert.Equal("value", viewData
[
"key"]);
190
Assert.Equal("value", viewContext.ViewData
[
"key"]);
Microsoft.AspNetCore.Mvc.RazorPages.Test (1)
Infrastructure\DefaultPageFactoryProviderTest.cs (1)
243
Assert.Equal("test-value", testPage.ViewData
[
"test-key"]);
Microsoft.AspNetCore.Mvc.TagHelpers.Test (2)
PartialTagHelperTest.cs (2)
241
v.Writer.Write(v.ViewData
[
"key"]);
285
v.Writer.Write(v.ViewData
[
"key"]);
Microsoft.AspNetCore.Mvc.ViewFeatures (3)
DefaultEditorTemplates.cs (2)
156
var htmlAttributesObject = viewData
[
HtmlAttributeKey];
173
var htmlAttributesObject = htmlHelper.ViewData
[
HtmlAttributeKey];
DynamicViewData.cs (1)
50
result = ViewData
[
binder.Name];
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (16)
ControllerTest.cs (1)
52
Assert.Equal("property", controller.ViewData
[
"Another"]);
Rendering\HtmlHelperDisplayExtensionsTest.cs (6)
52
.Callback((ViewContext v) => v.Writer.WriteAsync(v.ViewData
[
"SomeProperty"].ToString()))
187
.Callback((ViewContext v) => v.Writer.WriteAsync(v.ViewData
[
"SomeProperty"].ToString()))
243
.Callback((ViewContext v) => v.Writer.WriteAsync(v.ViewData
[
"SomeProperty"].ToString()))
290
.Callback((ViewContext v) => v.Writer.WriteAsync(v.ViewData
[
"SomeProperty"].ToString()))
415
.Callback((ViewContext v) => v.Writer.WriteAsync(v.ViewData
[
"SomeProperty"].ToString()))
462
.Callback((ViewContext v) => v.Writer.WriteAsync(v.ViewData
[
"SomeProperty"].ToString()))
Rendering\ViewContextTests.cs (1)
41
Assert.Equal("property", context.ViewData
[
"Another"]);
ViewComponentTests.cs (2)
29
Assert.Equal("Alice", viewComponent.ViewData
[
"A"]);
30
Assert.Equal("Bob", viewComponent.ViewData
[
"B"]);
ViewDataDictionaryOfTModelTest.cs (5)
56
Assert.Equal("bar", viewData1
[
"foo"]);
68
Assert.Equal("bar", viewData2
[
"foo"]);
95
Assert.Equal("bar", viewData1
[
"foo"]);
107
Assert.Equal("bar", viewData2
[
"foo"]);
175
Assert.Equal("value1", viewData
[
"key1"]);
ViewDataDictionaryTest.cs (1)
210
Assert.Equal("bar", viewData
[
"foo"]);
RazorWebSite (1)
Services\BackSlashExpander.cs (1)
17
if (context.ActionContext is ViewContext viewContext && (string)viewContext.ViewData
[
"back-slash"] == "true")