ProducesResponseTypeAttribute クラス

定義

アクションによって返される値と状態コードの種類を指定するフィルター。

public ref class ProducesResponseTypeAttribute : Attribute, Microsoft::AspNetCore::Mvc::ApiExplorer::IApiResponseMetadataProvider, Microsoft::AspNetCore::Mvc::Filters::IFilterMetadata
[System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Method, AllowMultiple=true, Inherited=true)]
public class ProducesResponseTypeAttribute : Attribute, Microsoft.AspNetCore.Mvc.ApiExplorer.IApiResponseMetadataProvider, Microsoft.AspNetCore.Mvc.Filters.IFilterMetadata
[<System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Method, AllowMultiple=true, Inherited=true)>]
type ProducesResponseTypeAttribute = class
    inherit Attribute
    interface IApiResponseMetadataProvider
    interface IFilterMetadata
Public Class ProducesResponseTypeAttribute
Inherits Attribute
Implements IApiResponseMetadataProvider, IFilterMetadata
継承
ProducesResponseTypeAttribute
派生
属性
実装

コンストラクター

ProducesResponseTypeAttribute(Int32)

ProducesResponseTypeAttribute のインスタンスを初期化します。

ProducesResponseTypeAttribute(Type, Int32)

ProducesResponseTypeAttribute のインスタンスを初期化します。

ProducesResponseTypeAttribute(Type, Int32, String, String[])

ProducesResponseTypeAttribute のインスタンスを初期化します。

プロパティ

StatusCode

応答の HTTP 状態コードを取得または設定します。

Type

アクションによって返される値の型を取得または設定します。

明示的なインターフェイスの実装

IApiResponseMetadataProvider.SetContentTypes(MediaTypeCollection)

アクションによって生成できる許可されたコンテンツ タイプのコレクションを構成します。

適用対象