11 writes to ViewData
Microsoft.AspNetCore.Mvc.RazorPages (3)
Infrastructure\PageActionInvokerProvider.cs (1)
85ViewData = cacheEntry.ViewDataFactory(_modelMetadataProvider, actionContext.ModelState),
Infrastructure\PageRequestDelegateFactory.cs (1)
99pageContext.ViewData = cacheEntry.ViewDataFactory(_modelMetadataProvider, pageContext.ModelState);
Infrastructure\PageResultExecutor.cs (1)
90pageContext.ViewData = currentViewContext.ViewData;
Microsoft.AspNetCore.Mvc.RazorPages.Test (8)
Infrastructure\DefaultPageFactoryProviderTest.cs (1)
221ViewData = new ViewDataDictionary<TestPage>(modelMetadataProvider, new ModelStateDictionary())
Infrastructure\PageActionInvokerTest.cs (1)
1514pageContext.ViewData = viewDataFactory(new EmptyModelMetadataProvider(), pageContext.ModelState);
PageModelTest.cs (5)
1729ViewData = viewData, 1945ViewData = viewData 1969ViewData = viewData 1993ViewData = viewData, 2015ViewData = viewData,
PageTest.cs (1)
31ViewData = viewData,
17 references to ViewData
Microsoft.AspNetCore.Mvc.RazorPages (9)
Infrastructure\PageActionInvoker.cs (6)
113_pageContext.ViewData, 125pageResult.ViewData = pageResult.ViewData ?? _pageContext.ViewData; 142_pageContext.ViewData.Model = _pageModel; 152_pageContext.ViewData, 166_pageContext.ViewData.Model = _page; 295pageResult.ViewData = pageResult.ViewData ?? _pageContext.ViewData;
Infrastructure\PageResultExecutor.cs (2)
58pageContext.ViewData.Model = result.Model; 100viewDataValuesProvider?.ProvideViewDataValues(pageContext.ViewData);
PageModel.cs (1)
150public ViewDataDictionary ViewData => PageContext?.ViewData!;
Microsoft.AspNetCore.Mvc.RazorPages.Test (7)
Infrastructure\DefaultPageFactoryProviderTest.cs (2)
230ViewData = pageContext.ViewData, 242Assert.Same(pageContext.ViewData, testPage.ViewData);
Infrastructure\PageActionInvokerProviderTest.cs (1)
145Assert.NotNull(Assert.IsType<ViewDataDictionary<TestPageModel>>(pageContext.ViewData));
Infrastructure\PageActionInvokerTest.cs (4)
256Assert.IsType<ViewDataDictionary<PocoModel>>(page.PageContext.ViewData); 257Assert.Null(page.PageContext.ViewData.Model); 316Assert.IsType<ViewDataDictionary<TestPageModel>>(pageModel.PageContext.ViewData); 322Assert.Same(pageModel.PageContext.ViewData, pageResult.ViewData);
RazorBuildWebSite.Views (1)
Pages\Rzc\Page.cs (1)
37public global::Microsoft.AspNetCore.Mvc.ViewFeatures.ViewDataDictionary<Page_Model> ViewData => (global::Microsoft.AspNetCore.Mvc.ViewFeatures.ViewDataDictionary<Page_Model>)PageContext?.ViewData;