JsonResult クラス

定義

指定されたオブジェクトを JSON として書式設定するアクションの結果。

public ref class JsonResult : Microsoft::AspNetCore::Mvc::ActionResult
public ref class JsonResult : Microsoft::AspNetCore::Mvc::ActionResult, Microsoft::AspNetCore::Mvc::IActionResult, Microsoft::AspNetCore::Mvc::Infrastructure::IStatusCodeActionResult
public class JsonResult : Microsoft.AspNetCore.Mvc.ActionResult
public class JsonResult : Microsoft.AspNetCore.Mvc.ActionResult, Microsoft.AspNetCore.Mvc.IActionResult, Microsoft.AspNetCore.Mvc.Infrastructure.IStatusCodeActionResult
type JsonResult = class
    inherit ActionResult
type JsonResult = class
    inherit ActionResult
    interface IStatusCodeActionResult
    interface IActionResult
type JsonResult = class
    inherit ActionResult
    interface IActionResult
    interface IStatusCodeActionResult
Public Class JsonResult
Inherits ActionResult
Public Class JsonResult
Inherits ActionResult
Implements IActionResult, IStatusCodeActionResult
継承
JsonResult
実装

コンストラクター

JsonResult(Object)

指定valueした を使用して新しい JsonResult を作成します。

JsonResult(Object, JsonSerializerSettings)

指定valueした を使用して新しい JsonResult を作成します。

JsonResult(Object, Object)

指定valueした を使用して新しい JsonResult を作成します。

プロパティ

ContentType

応答の MediaTypeHeaderValue Content-Type ヘッダーを表す を取得または設定します。

SerializerSettings

シリアライザーの設定を取得または設定します。

を使用 System.Text.Jsonする場合、これは のインスタンスである必要があります JsonSerializerOptions

を使用 Newtonsoft.Jsonする場合、これは の JsonSerializerSettingsインスタンスである必要があります。

StatusCode

HTTP ステータス コードを取得または設定します。

Value

書式設定する値を取得または設定します。

メソッド

ExecuteResult(ActionContext)

アクション メソッドの結果操作を同期的に実行します。 このメソッドは、アクション メソッドの結果を処理するために MVC によって呼び出されます。

(継承元 ActionResult)
ExecuteResultAsync(ActionContext)

アクション メソッドの結果操作を非同期的に実行します。 このメソッドは、アクション メソッドの結果を処理するために MVC によって呼び出されます。

適用対象