HttpPostAttribute Class¶
Identifies an action that only supports the HTTP POST method.
- Namespace
Microsoft.AspNetCore.Mvc- Assemblies
- Microsoft.AspNetCore.Mvc.Core
Inheritance Hierarchy¶
System.ObjectSystem.AttributeMicrosoft.AspNetCore.Mvc.Routing.HttpMethodAttributeMicrosoft.AspNetCore.Mvc.HttpPostAttribute
Syntax¶
public class HttpPostAttribute : HttpMethodAttribute, _Attribute, IActionHttpMethodProvider, IRouteTemplateProvider
-
class
Microsoft.AspNetCore.Mvc.HttpPostAttribute
Constructors¶
-
HttpPostAttribute()¶ Creates a new
Microsoft.AspNetCore.Mvc.HttpPostAttribute.public HttpPostAttribute()
-
HttpPostAttribute(System.String) Creates a new
Microsoft.AspNetCore.Mvc.HttpPostAttributewith the given route template.Arguments: template (System.String) – The route template. May not be null. public HttpPostAttribute(string template)
-