HttpMethodActionConstraint(IEnumerable<String>) 构造函数

定义

创建 HttpMethodActionConstraint 的新实例。

public:
 HttpMethodActionConstraint(System::Collections::Generic::IEnumerable<System::String ^> ^ httpMethods);
public HttpMethodActionConstraint (System.Collections.Generic.IEnumerable<string> httpMethods);
new Microsoft.AspNetCore.Mvc.ActionConstraints.HttpMethodActionConstraint : seq<string> -> Microsoft.AspNetCore.Mvc.ActionConstraints.HttpMethodActionConstraint
Public Sub New (httpMethods As IEnumerable(Of String))

参数

httpMethods
IEnumerable<String>

要允许的 HTTP 方法的列表。 提供空列表将允许任何 HTTP 方法。

适用于