16 references to HttpMethods
Microsoft.AspNetCore.Mvc.ApiExplorer (1)
DefaultApiDescriptionProvider.cs (1)
367
return action.ActionConstraints.OfType<HttpMethodActionConstraint>().SelectMany(c => c.
HttpMethods
);
Microsoft.AspNetCore.Mvc.Core (2)
ApplicationModels\ApplicationModelFactory.cs (1)
303
var verbs = selector.ActionConstraints?.OfType<HttpMethodActionConstraint>().FirstOrDefault()?.
HttpMethods
;
Routing\ActionEndpointFactory.cs (1)
421
builder.Metadata.Add(new HttpMethodMetadata(httpMethodActionConstraint.
HttpMethods
));
Microsoft.AspNetCore.Mvc.Core.Test (11)
ApplicationModels\ControllerActionDescriptorProviderTests.cs (11)
95
Assert.Equal(new string[] { "POST" }, constraint.
HttpMethods
);
112
Assert.Equal(new string[] { "PUT", "PATCH" }, constraint.
HttpMethods
);
488
Assert.NotNull(methodConstraint.
HttpMethods
);
489
Assert.Equal(new[] { "POST" }, methodConstraint.
HttpMethods
);
513
Assert.NotNull(methodConstraint.
HttpMethods
);
514
Assert.Equal(new[] { "PUT" }, methodConstraint.
HttpMethods
);
546
a => a.ActionConstraints.OfType<HttpMethodActionConstraint>().Single().
HttpMethods
.Single() == "PUT");
553
a => a.ActionConstraints.OfType<HttpMethodActionConstraint>().Single().
HttpMethods
.Single() == "POST");
585
a => a.ActionConstraints.OfType<HttpMethodActionConstraint>().Single().
HttpMethods
.Single() == "POST");
592
a => a.ActionConstraints.OfType<HttpMethodActionConstraint>().Single().
HttpMethods
.Single() == "PUT");
648
.SelectMany(c => c.
HttpMethods
)
Microsoft.AspNetCore.Mvc.Cors (2)
CorsHttpMethodActionConstraint.cs (2)
16
: base(constraint.
HttpMethods
)
24
var methods = (ReadOnlyCollection<string>)
HttpMethods
;