共用方式為


SystemTextJsonOutputFormatter.WriteResponseBodyAsync 方法

定義

寫入回應本文。

public:
 override System::Threading::Tasks::Task ^ WriteResponseBodyAsync(Microsoft::AspNetCore::Mvc::Formatters::OutputFormatterWriteContext ^ context, System::Text::Encoding ^ selectedEncoding);
public override sealed System.Threading.Tasks.Task WriteResponseBodyAsync (Microsoft.AspNetCore.Mvc.Formatters.OutputFormatterWriteContext context, System.Text.Encoding selectedEncoding);
override this.WriteResponseBodyAsync : Microsoft.AspNetCore.Mvc.Formatters.OutputFormatterWriteContext * System.Text.Encoding -> System.Threading.Tasks.Task
Public Overrides NotOverridable Function WriteResponseBodyAsync (context As OutputFormatterWriteContext, selectedEncoding As Encoding) As Task

參數

context
OutputFormatterWriteContext

與呼叫相關聯的格式器內容。

selectedEncoding
Encoding

Encoding應該用來寫入回應的 。

傳回

可寫入回應本文的工作。

適用於