IApiResponseTypeMetadataProvider Interface¶
Provides metadata information about the response format to an <code>IApiDescriptionProvider</code>.
- Namespace
Microsoft.AspNetCore.Mvc.ApiExplorer
- Assemblies
- Microsoft.AspNetCore.Mvc.Core
Syntax¶
public interface IApiResponseTypeMetadataProvider
-
interface
Microsoft.AspNetCore.Mvc.ApiExplorer.
IApiResponseTypeMetadataProvider
Methods¶
-
GetSupportedContentTypes
(System.String, System.Type)¶ Gets a filtered list of content types which are supported by the
Microsoft.AspNetCore.Mvc.Formatters.IOutputFormatter
for the <em>objectType</em> and <em>contentType</em>.Arguments: - contentType (System.String) – The content type for which the supported content types are desired, or <code>null</code> if any content type can be used.
- objectType (System.Type) – The
System.Type
for which the supported content types are desired.
Return type: System.Collections.Generic.IReadOnlyList<System.String>
Returns: Content types which are supported by the
Microsoft.AspNetCore.Mvc.Formatters.IOutputFormatter
.IReadOnlyList<string> GetSupportedContentTypes(string contentType, Type objectType)
-