20 writes to Template
ApiExplorerWebSite (1)
ApiExplorerRouteChangeConvention.cs (1)
27Template = "NewIndex"
Microsoft.AspNetCore.Mvc.Core (4)
ApplicationModels\ApplicationModelFactory.cs (1)
147selector.AttributeRouteModel.Template = AttributeRouteModel.ReplaceTokens(
ApplicationModels\AttributeRouteModel.cs (3)
36Template = templateProvider.Template; 52Template = other.Template; 125Template = combinedTemplate,
Microsoft.AspNetCore.Mvc.Core.Test (6)
ApplicationModels\AttributeRouteModelTests.cs (5)
286Template = "Template" 304Template = "Template", 323Template = "Template", 341Template = "Template", 794Template = template,
ApplicationModels\ControllerActionDescriptorProviderTests.cs (1)
1958Template = "/!!!",
Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation (1)
src\Mvc\Mvc.RazorPages\src\ApplicationModels\PageRouteModelFactory.cs (1)
164Template = AttributeRouteModel.CombineTemplates(prefix, routeTemplate),
Microsoft.AspNetCore.Mvc.RazorPages (2)
ApplicationModels\PageRouteModelFactory.cs (1)
164Template = AttributeRouteModel.CombineTemplates(prefix, routeTemplate),
DependencyInjection\PageConventionCollectionExtensions.cs (1)
436Template = route,
Microsoft.AspNetCore.Mvc.RazorPages.Test (6)
DependencyInjection\PageConventionCollectionExtensionsTest.cs (1)
991Template = template,
Infrastructure\PageActionDescriptorProviderTest.cs (5)
44Template = "/Test/{id:int?}", 83Template = "/Test/{id:int?}", 133Template = "Accounts/Test/{id:int?}", 298Template = template, 354Template = "Home",
63 references to Template
ApplicationModelWebSite (1)
Controllers\HomeController.cs (1)
44var selector = model.Selectors.First(f => f.AttributeRouteModel.Template == "Home/CannotBeRouted");
Microsoft.AspNetCore.Mvc.Core (14)
ApplicationModels\ApplicationModelFactory.cs (5)
148selector.AttributeRouteModel.Template!, 232var template = actions[0].selector.AttributeRouteModel!.Template!; 236var other = actions[i].selector.AttributeRouteModel!.Template; 242return Resources.FormatAttributeRoute_DuplicateNames_Item(a.action.DisplayName, a.selector.AttributeRouteModel!.Template); 301var routeTemplate = selector.AttributeRouteModel?.Template ?? nullTemplate;
ApplicationModels\AttributeRouteModel.cs (7)
52Template = other.Template; 91public bool IsAbsoluteTemplate => Template != null && IsOverridePattern(Template); 110if (left == null || IsOverridePattern(right.Template)) 115var combinedTemplate = CombineTemplates(left.Template, right.Template); 164if (right.Name == null && string.IsNullOrEmpty(right.Template))
ApplicationModels\ControllerActionDescriptorBuilder.cs (1)
203Template = selectorModel.AttributeRouteModel.Template,
ApplicationModels\InferParameterBindingInfoConvention.cs (1)
162var parsedTemplate = TemplateParser.Parse(selector.AttributeRouteModel.Template!);
Microsoft.AspNetCore.Mvc.Core.Test (12)
ApplicationModels\AttributeRouteModelTests.cs (4)
231Assert.Equal(expectedResult.Template, combined.Template); 254var expectedTemplate = AttributeRouteModel.CombineTemplates(null, right.Template); 261Assert.Equal(expectedTemplate, combined.Template);
ApplicationModels\DefaultApplicationModelProviderTest.cs (8)
446var route = Assert.Single(attributeRoutes, r => r.Template == "A"); 449route = Assert.Single(attributeRoutes, r => r.Template == "B"); 468var route = Assert.Single(attributeRoutes, r => r.Template == "C"); 471route = Assert.Single(attributeRoutes, r => r.Template == "D"); 882Assert.Equal("Change", attributeRoute.Template); 906Assert.Equal("Update", attributeRoute.Template); 935Assert.Equal("ListAll", attributeRoute.Template); 1069Assert.Equal("Products", attributeRoute.Template);
Microsoft.AspNetCore.Mvc.RazorPages (2)
Infrastructure\PageActionDescriptorProvider.cs (2)
132return selectorModel.AttributeRouteModel!.Template; 141return selectorModel.AttributeRouteModel!.Template;
Microsoft.AspNetCore.Mvc.RazorPages.Test (34)
ApplicationModels\CompiledPageRouteModelProviderTest.cs (20)
44selector => Assert.Equal("About", selector.AttributeRouteModel.Template)); 59selector => Assert.Equal("Home/some-prefix", selector.AttributeRouteModel.Template)); 106selector => Assert.Equal("Products/About", selector.AttributeRouteModel.Template)); 125selector => Assert.Equal("Products/Manage/Index", selector.AttributeRouteModel.Template), 126selector => Assert.Equal("Products/Manage", selector.AttributeRouteModel.Template)); 146selector => Assert.Equal("Products/Manage/Edit/{id}", selector.AttributeRouteModel.Template)); 194selector => Assert.Equal("Accounts/Manage/Home", selector.AttributeRouteModel.Template)); 214selector => Assert.Equal("Contact", selector.AttributeRouteModel.Template)); 254selector => Assert.Equal("Pages/Index", selector.AttributeRouteModel.Template), 255selector => Assert.Equal("Pages", selector.AttributeRouteModel.Template)); 263selector => Assert.Equal("Pages/Admin/Index/some-template", selector.AttributeRouteModel.Template), 264selector => Assert.Equal("Pages/Admin/some-template", selector.AttributeRouteModel.Template)); 296selector => Assert.Equal("Index", selector.AttributeRouteModel.Template), 297selector => Assert.Equal("", selector.AttributeRouteModel.Template)); 305selector => Assert.Equal("Admin/Index/some-template", selector.AttributeRouteModel.Template), 306selector => Assert.Equal("Admin/some-template", selector.AttributeRouteModel.Template)); 341selector => Assert.Equal("some-other-prefix", selector.AttributeRouteModel.Template)); 349selector => Assert.Equal("some-prefix", selector.AttributeRouteModel.Template)); 416selector => Assert.Equal("_About", selector.AttributeRouteModel.Template)); 431selector => Assert.Equal("Home", selector.AttributeRouteModel.Template));
ApplicationModels\PageRouteModelFactoryTest.cs (7)
29selector => Assert.Equal("Users/Profile/{id?}", selector.AttributeRouteModel.Template)); 57selector => Assert.Equal("Users/Profile/Index/{id?}", selector.AttributeRouteModel.Template), 58selector => Assert.Equal("Users/Profile/{id?}", selector.AttributeRouteModel.Template)); 86selector => Assert.Equal("my-override", selector.AttributeRouteModel.Template)); 115selector => Assert.Equal("TestArea/Users/Profile/{id?}", selector.AttributeRouteModel.Template)); 149selector => Assert.Equal("TestArea/Users/Profile/Index/{id?}", selector.AttributeRouteModel.Template), 150selector => Assert.Equal("TestArea/Users/Profile/{id?}", selector.AttributeRouteModel.Template));
DependencyInjection\PageConventionCollectionExtensionsTest.cs (7)
894Assert.Equal("Index", selector.AttributeRouteModel.Template); 899Assert.Equal("", selector.AttributeRouteModel.Template); 904Assert.Equal("Different-Route", selector.AttributeRouteModel.Template); 914Assert.Equal("About", selector.AttributeRouteModel.Template); 955Assert.Equal("Profile", selector.AttributeRouteModel.Template); 965Assert.Equal("Accounts/Profile", selector.AttributeRouteModel.Template); 970Assert.Equal("Different-Route", selector.AttributeRouteModel.Template);