ApiConventionMethodAttribute(Type, String) Konstruktor

Definicja

Inicjuje ApiConventionMethodAttribute wystąpienie przy użyciu polecenia conventionType i określony methodNameelement .

public:
 ApiConventionMethodAttribute(Type ^ conventionType, System::String ^ methodName);
public ApiConventionMethodAttribute (Type conventionType, string methodName);
new Microsoft.AspNetCore.Mvc.ApiConventionMethodAttribute : Type * string -> Microsoft.AspNetCore.Mvc.ApiConventionMethodAttribute
Public Sub New (conventionType As Type, methodName As String)

Parametry

conventionType
Type

Konwencja Type .

Konwencje muszą być typami statycznymi. Metody w konwencji są dopasowywane do metody akcji przy użyciu reguł określonych przez ApiConventionNameMatchAttribute , które mogą być stosowane do nazwy metody lub jej parametrów i ApiConventionTypeMatchAttribute które są stosowane do parametrów.

methodName
String

Nazwa metody.

Dotyczy