3 writes to ActionConstraints
Microsoft.AspNetCore.Mvc.Core (2)
ApplicationModels\SelectorModel.cs (2)
18
ActionConstraints
= new List<IActionConstraintMetadata>();
30
ActionConstraints
= new List<IActionConstraintMetadata>(other.ActionConstraints);
Microsoft.AspNetCore.Mvc.RazorPages.Test (1)
Infrastructure\PageActionDescriptorProviderTest.cs (1)
180
ActionConstraints
= { expected }
29 references to ActionConstraints
Microsoft.AspNetCore.Mvc.Core (13)
ApplicationModels\ActionAttributeRouteModel.cs (7)
37
for (var i = additionalSelector.
ActionConstraints
.Count - 1; i >= 0; i--)
39
if (additionalSelector.
ActionConstraints
[i] is IRouteTemplateProvider)
41
additionalSelector.
ActionConstraints
.RemoveAt(i);
73
AddActionConstraints(selector, additionalSelector?.
ActionConstraints
);
91
AddActionConstraints(selector, controllerSelector.
ActionConstraints
);
110
AddActionConstraints(selector, additionalSelector?.
ActionConstraints
);
124
selector.
ActionConstraints
.Add(actionConstraints[i]);
ApplicationModels\ApplicationModelFactory.cs (1)
303
var verbs = selector.
ActionConstraints
?.OfType<HttpMethodActionConstraint>().FirstOrDefault()?.HttpMethods;
ApplicationModels\ControllerActionDescriptorBuilder.cs (2)
183
if (selectorModel.
ActionConstraints
?.Count > 0)
185
actionDescriptor.ActionConstraints = new List<IActionConstraintMetadata>(selectorModel.
ActionConstraints
);
ApplicationModels\DefaultApplicationModelProvider.cs (2)
628
AddRange(selectorModel.
ActionConstraints
, attributes.OfType<IActionConstraintMetadata>());
640
selectorModel.
ActionConstraints
.Add(new HttpMethodActionConstraint(httpMethods));
ApplicationModels\SelectorModel.cs (1)
30
ActionConstraints = new List<IActionConstraintMetadata>(other.
ActionConstraints
);
Microsoft.AspNetCore.Mvc.Core.Test (4)
ApplicationModels\ActionModelTest.cs (1)
69
selectorModel.
ActionConstraints
.Add(new HttpMethodActionConstraint(new string[] { "GET" }));
ApplicationModels\ControllerModelTest.cs (3)
48
Assert.NotSame(controller.Selectors[0].
ActionConstraints
, controller2.Selectors[0].
ActionConstraints
);
73
selectorModel.
ActionConstraints
.Add(new HttpMethodActionConstraint(new string[] { "GET" }));
Microsoft.AspNetCore.Mvc.Cors (1)
CorsApplicationModelProvider.cs (1)
95
var actionConstraints = selectorModel.
ActionConstraints
;
Microsoft.AspNetCore.Mvc.Cors.Test (10)
CorsApplicationModelProviderTest.cs (10)
37
var constraint = Assert.Single(selector.
ActionConstraints
, c => c is HttpMethodActionConstraint);
56
var constraint = Assert.Single(selector.
ActionConstraints
, c => c is HttpMethodActionConstraint);
74
var constraint = Assert.Single(selector.
ActionConstraints
, c => c is HttpMethodActionConstraint);
93
var constraint = Assert.Single(selector.
ActionConstraints
, c => c is HttpMethodActionConstraint);
112
var constraint = Assert.Single(selector.
ActionConstraints
, c => c is HttpMethodActionConstraint);
130
var constraint = Assert.Single(selector.
ActionConstraints
, c => c is HttpMethodActionConstraint);
151
var constraint = Assert.Single(selector.
ActionConstraints
, c => c is HttpMethodActionConstraint);
170
var constraint = Assert.Single(selector.
ActionConstraints
, c => c is HttpMethodActionConstraint);
189
var constraint = Assert.Single(selector.
ActionConstraints
, c => c is HttpMethodActionConstraint);
207
var constraint = Assert.Single(selector.
ActionConstraints
, c => c is HttpMethodActionConstraint);
Microsoft.AspNetCore.Mvc.RazorPages (1)
Infrastructure\PageActionDescriptorProvider.cs (1)
92
ActionConstraints = selector.
ActionConstraints
.ToList(),