Partager via


AcceptVerbsAttribute Constructor

Initializes a new instance of the AcceptVerbsAttribute class by using a list of HTTP methods that the action method will respond to.

Namespace:  System.Web.Http
Assembly:  System.Web.Http (in System.Web.Http.dll)

Syntax

'Declaration
Public Sub New ( _
    ParamArray methods As String() _
)
'Usage
Dim methods As String()

Dim instance As New AcceptVerbsAttribute(methods)
public AcceptVerbsAttribute(
    params string[] methods
)
public:
AcceptVerbsAttribute(
    ... array<String^>^ methods
)
new : 
        methods:string[] -> AcceptVerbsAttribute
public function AcceptVerbsAttribute(
    ... methods : String[]
)

Parameters

  • methods
    Type: System.String[]
    The HTTP methods that the action method will respond to.

See Also

Reference

AcceptVerbsAttribute Class

System.Web.Http Namespace