35 instantiations of SelectorModel
ApiExplorerWebSite (1)
ApiExplorerRouteChangeConvention.cs (1)
23
action.Selectors.Add(new
SelectorModel
Microsoft.AspNetCore.Mvc.Core (7)
ApplicationModels\ActionAttributeRouteModel.cs (4)
34
additionalSelector = new
SelectorModel
(actionModel.Controller.Selectors[0]);
67
var selector = new
SelectorModel
(actionSelector);
85
var selector = new
SelectorModel
(actionSelector);
104
var selector = new
SelectorModel
(actionSelector);
ApplicationModels\ActionModel.cs (1)
67
Selectors = new List<SelectorModel>(other.Selectors.Select(s => new
SelectorModel
(s)));
ApplicationModels\ControllerModel.cs (1)
68
Selectors = new List<SelectorModel>(other.Selectors.Select(s => new
SelectorModel
(s)));
ApplicationModels\DefaultApplicationModelProvider.cs (1)
622
var selectorModel = new
SelectorModel
();
Microsoft.AspNetCore.Mvc.Core.Test (15)
ApplicationModels\ActionModelTest.cs (2)
28
action.Selectors.Add(new
SelectorModel
()
68
var selectorModel = new
SelectorModel
();
ApplicationModels\ApiBehaviorApplicationModelProviderTest.cs (4)
46
Selectors = { new
SelectorModel
{ AttributeRouteModel = new AttributeRouteModel() } },
54
Selectors = { new
SelectorModel
{ AttributeRouteModel = new AttributeRouteModel() } },
89
Selectors = { new
SelectorModel
{ AttributeRouteModel = new AttributeRouteModel() } },
97
Selectors = { new
SelectorModel
{ AttributeRouteModel = new AttributeRouteModel() } },
ApplicationModels\ControllerActionDescriptorBuilderTest.cs (4)
41
actionModel.Selectors.Add(new
SelectorModel
());
73
actionModel.Selectors.Add(new
SelectorModel
());
99
actionModel.Selectors.Add(new
SelectorModel
());
125
actionModel.Selectors.Add(new
SelectorModel
());
ApplicationModels\ControllerActionDescriptorProviderTests.cs (1)
1954
action.Selectors.Add(new
SelectorModel
()
ApplicationModels\ControllerModelTest.cs (2)
30
controller.Selectors.Add(new
SelectorModel
() { AttributeRouteModel = route });
72
var selectorModel = new
SelectorModel
();
ApplicationModels\RouteTokenTransformerConventionTest.cs (2)
19
model.Selectors.Add(new
SelectorModel
()
39
model.Selectors.Add(new
SelectorModel
()
Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation (1)
src\Mvc\Mvc.RazorPages\src\ApplicationModels\PageRouteModelFactory.cs (1)
160
return new
SelectorModel
Microsoft.AspNetCore.Mvc.RazorPages (3)
ApplicationModels\PageRouteModel.cs (1)
56
Selectors = new List<SelectorModel>(other.Selectors.Select(m => new
SelectorModel
(m)));
ApplicationModels\PageRouteModelFactory.cs (1)
160
return new
SelectorModel
DependencyInjection\PageConventionCollectionExtensions.cs (1)
432
model.Selectors.Add(new
SelectorModel
Microsoft.AspNetCore.Mvc.RazorPages.Test (8)
DependencyInjection\PageConventionCollectionExtensionsTest.cs (1)
987
return new
SelectorModel
Infrastructure\PageActionDescriptorProviderTest.cs (7)
40
new
SelectorModel
79
new
SelectorModel
129
new
SelectorModel
177
new
SelectorModel
211
new
SelectorModel
294
return new
SelectorModel
350
new
SelectorModel
77 references to SelectorModel
ApplicationModelWebSite (1)
Controllers\HomeController.cs (1)
44
var
selector = model.Selectors.First(f => f.AttributeRouteModel.Template == "Home/CannotBeRouted");
Microsoft.AspNetCore.Mvc.Core (49)
ApplicationModels\ActionAttributeRouteModel.cs (13)
12
public static IEnumerable<
SelectorModel
> FlattenSelectors(ActionModel actionModel)
22
SelectorModel
? additionalSelector = null;
56
foreach (
var
actionSelector in actionModel.Selectors)
67
var
selector = new SelectorModel(actionSelector);
82
var
controllerSelector = controllerSelectors[i];
85
var
selector = new SelectorModel(actionSelector);
104
var
selector = new SelectorModel(actionSelector);
118
private static void AddActionConstraints(
SelectorModel
selector, IList<IActionConstraintMetadata>? actionConstraints)
129
private static void AddEndpointMetadata(
SelectorModel
selector, IList<object>? controllerMetadata)
143
public static IEnumerable<(AttributeRouteModel? route,
SelectorModel
actionSelector,
SelectorModel
? controllerSelector)> GetAttributeRoutes(ActionModel actionModel)
150
foreach (
var
actionSelectorModel in actionModel.Selectors)
170
var
controllerSelector = actionModel.Controller.Selectors[i];
ApplicationModels\ActionModel.cs (4)
40
Selectors = new List<
SelectorModel
>();
67
Selectors = new List<
SelectorModel
>(other.Selectors.Select(s => new SelectorModel(s)));
158
/// Gets the <see cref="
SelectorModel
"/> instances.
160
public IList<
SelectorModel
> Selectors { get; }
ApplicationModels\ApiBehaviorApplicationModelProvider.cs (1)
103
static bool IsAttributeRouted(IList<
SelectorModel
> selectorModel)
ApplicationModels\ApplicationModelFactory.cs (14)
56
Func<ApplicationModel, ControllerModel, ActionModel,
SelectorModel
, TResult> flattener)
60
var actionsByMethod = new Dictionary<MethodInfo, List<(ActionModel,
SelectorModel
)>>();
61
var actionsByRouteName = new Dictionary<string, List<(ActionModel,
SelectorModel
)>>(StringComparer.OrdinalIgnoreCase);
69
foreach (
var
selector in ActionAttributeRouteModel.FlattenSelectors(action))
121
SelectorModel
selector,
174
Dictionary<MethodInfo, List<(ActionModel,
SelectorModel
)>> actionsByMethod,
176
SelectorModel
selector)
180
actions = new List<(ActionModel,
SelectorModel
)>();
188
Dictionary<string, List<(ActionModel action,
SelectorModel
selector)>> actionsByRouteName,
190
SelectorModel
selector)
200
actions = new List<(ActionModel,
SelectorModel
)>();
219
Dictionary<string, List<(ActionModel action,
SelectorModel
selector)>> actionsByRouteName)
257
List<(ActionModel action,
SelectorModel
selector)> actions,
292
List<(ActionModel action,
SelectorModel
selector)> actions)
ApplicationModels\ControllerActionDescriptorBuilder.cs (4)
30
SelectorModel
selector)
181
private static void AddActionConstraints(ControllerActionDescriptor actionDescriptor,
SelectorModel
selectorModel)
189
private static void AddEndpointMetadata(ControllerActionDescriptor actionDescriptor,
SelectorModel
selectorModel)
197
private static void AddAttributeRoute(ControllerActionDescriptor actionDescriptor,
SelectorModel
selectorModel)
ApplicationModels\ControllerModel.cs (3)
40
Selectors = new List<
SelectorModel
>();
68
Selectors = new List<
SelectorModel
>(other.Selectors.Select(s => new SelectorModel(s)));
145
public IList<
SelectorModel
> Selectors { get; }
ApplicationModels\DefaultApplicationModelProvider.cs (4)
461
private static IList<
SelectorModel
> CreateSelectors(IList<object> attributes)
543
var selectorModels = new List<
SelectorModel
>();
620
private static
SelectorModel
CreateSelectorModel(IRouteTemplateProvider? route, IList<object> attributes)
622
var
selectorModel = new SelectorModel();
ApplicationModels\InferParameterBindingInfoConvention.cs (1)
155
foreach (
var
selector in ActionAttributeRouteModel.FlattenSelectors(action))
ApplicationModels\SelectorModel.cs (5)
14
/// Intializes a new <see cref="
SelectorModel
"/>.
23
/// Intializes a new <see cref="
SelectorModel
"/>.
25
/// <param name="other">The <see cref="
SelectorModel
"/> to copy from.</param>
26
public SelectorModel(
SelectorModel
other)
50
/// Gets the <see cref="EndpointMetadata"/> associated with the <see cref="
SelectorModel
"/>.
Microsoft.AspNetCore.Mvc.Core.Test (3)
ApplicationModels\ActionModelTest.cs (1)
68
var
selectorModel = new SelectorModel();
ApplicationModels\ControllerModelTest.cs (1)
72
var
selectorModel = new SelectorModel();
ApplicationModels\DefaultApplicationModelProviderTest.cs (1)
1384
private IList<AttributeRouteModel> GetAttributeRoutes(IList<
SelectorModel
> selectors)
Microsoft.AspNetCore.Mvc.Cors (1)
CorsApplicationModelProvider.cs (1)
93
var
selectorModel = selectors[i];
Microsoft.AspNetCore.Mvc.Cors.Test (10)
CorsApplicationModelProviderTest.cs (10)
36
var
selector = Assert.Single(action.Selectors);
55
var
selector = Assert.Single(action.Selectors);
73
var
selector = Assert.Single(action.Selectors);
92
var
selector = Assert.Single(action.Selectors);
111
var
selector = Assert.Single(action.Selectors);
129
var
selector = Assert.Single(action.Selectors);
150
var
selector = Assert.Single(action.Selectors);
169
var
selector = Assert.Single(action.Selectors);
188
var
selector = Assert.Single(action.Selectors);
206
var
selector = Assert.Single(action.Selectors);
Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation (2)
src\Mvc\Mvc.RazorPages\src\ApplicationModels\PageRouteModelFactory.cs (2)
60
var
selectorModel = CreateSelectorModel(pageRoute, routeTemplate);
158
private static
SelectorModel
CreateSelectorModel(string prefix, string? routeTemplate)
Microsoft.AspNetCore.Mvc.RazorPages (9)
ApplicationModels\PageRouteModel.cs (4)
38
Selectors = new List<
SelectorModel
>();
56
Selectors = new List<
SelectorModel
>(other.Selectors.Select(m => new SelectorModel(m)));
89
/// Gets the <see cref="
SelectorModel
"/> instances.
91
public IList<
SelectorModel
> Selectors { get; }
ApplicationModels\PageRouteModelFactory.cs (2)
60
var
selectorModel = CreateSelectorModel(pageRoute, routeTemplate);
158
private static
SelectorModel
CreateSelectorModel(string prefix, string? routeTemplate)
DependencyInjection\PageConventionCollectionExtensions.cs (1)
427
foreach (
var
selector in model.Selectors)
Infrastructure\PageActionDescriptorProvider.cs (2)
88
foreach (
var
selector in model.Selectors)
127
private static string? TransformPageRoute(PageRouteModel model,
SelectorModel
selectorModel)
Microsoft.AspNetCore.Mvc.RazorPages.Test (2)
DependencyInjection\PageConventionCollectionExtensionsTest.cs (1)
985
private static
SelectorModel
CreateSelectorModel(string template, bool suppressLinkGeneration = false)
Infrastructure\PageActionDescriptorProviderTest.cs (1)
292
private static
SelectorModel
CreateSelectorModel(string template)