TextOutputFormatter.WriteResponseBodyAsync 方法

定义

重载

WriteResponseBodyAsync(OutputFormatterWriteContext)

写入响应正文。

WriteResponseBodyAsync(OutputFormatterWriteContext, Encoding)

写入响应正文。

WriteResponseBodyAsync(OutputFormatterWriteContext)

Source:
TextOutputFormatter.cs
Source:
TextOutputFormatter.cs
Source:
TextOutputFormatter.cs

写入响应正文。

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

参数

context
OutputFormatterWriteContext

与调用关联的格式化程序上下文。

返回

可以写入响应正文的任务。

适用于

WriteResponseBodyAsync(OutputFormatterWriteContext, Encoding)

Source:
TextOutputFormatter.cs
Source:
TextOutputFormatter.cs
Source:
TextOutputFormatter.cs

写入响应正文。

public:
 abstract System::Threading::Tasks::Task ^ WriteResponseBodyAsync(Microsoft::AspNetCore::Mvc::Formatters::OutputFormatterWriteContext ^ context, System::Text::Encoding ^ selectedEncoding);
public abstract 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 MustOverride Function WriteResponseBodyAsync (context As OutputFormatterWriteContext, selectedEncoding As Encoding) As Task

参数

context
OutputFormatterWriteContext

与调用关联的格式化程序上下文。

selectedEncoding
Encoding

Encoding应用于写入响应的 。

返回

可以写入响应正文的任务。

适用于