IApiRequestFormatMetadataProvider.GetSupportedContentTypes 方法

定义

获取 和 contentType支持的内容类型IInputFormatterobjectType的筛选列表。

public:
 System::Collections::Generic::IReadOnlyList<System::String ^> ^ GetSupportedContentTypes(System::String ^ contentType, Type ^ objectType);
public System.Collections.Generic.IReadOnlyList<string> GetSupportedContentTypes (string contentType, Type objectType);
public System.Collections.Generic.IReadOnlyList<string>? GetSupportedContentTypes (string contentType, Type objectType);
abstract member GetSupportedContentTypes : string * Type -> System.Collections.Generic.IReadOnlyList<string>
Public Function GetSupportedContentTypes (contentType As String, objectType As Type) As IReadOnlyList(Of String)

参数

contentType
String

需要支持的内容类型的内容类型,或者 null 是否可以使用任何内容类型。

objectType
Type

Type需要其支持的内容类型的 。

返回

支持的 IInputFormatter内容类型。

适用于