RazorPage.WriteTo 方法

定义

重载

WriteTo(TextWriter, Object)

使用 HTML 编码将指定的 value 写入 writer

WriteTo(TextWriter, String)

使用 HTML 编码将指定的 value 写入 writer

WriteTo(TextWriter, HtmlEncoder, Object)

使用 HTML 编码将指定的 value 写入给定 writer的 。

WriteTo(TextWriter, Object)

使用 HTML 编码将指定的 value 写入 writer

public:
 virtual void WriteTo(System::IO::TextWriter ^ writer, System::Object ^ value);
public virtual void WriteTo (System.IO.TextWriter writer, object value);
abstract member WriteTo : System.IO.TextWriter * obj -> unit
override this.WriteTo : System.IO.TextWriter * obj -> unit
Public Overridable Sub WriteTo (writer As TextWriter, value As Object)

参数

writer
TextWriter

TextWriter 写入的实例。

value
Object

要写入的 Object

注解

value类型的 IHtmlContent s 是使用 写入的 WriteTo(TextWriter, HtmlEncoder)。 对于所有其他类型, 的ToString()编码结果将写入 。writer

适用于

WriteTo(TextWriter, String)

使用 HTML 编码将指定的 value 写入 writer

public:
 virtual void WriteTo(System::IO::TextWriter ^ writer, System::String ^ value);
public virtual void WriteTo (System.IO.TextWriter writer, string value);
abstract member WriteTo : System.IO.TextWriter * string -> unit
override this.WriteTo : System.IO.TextWriter * string -> unit
Public Overridable Sub WriteTo (writer As TextWriter, value As String)

参数

writer
TextWriter

TextWriter 写入的实例。

value
String

要写入的 String

适用于

WriteTo(TextWriter, HtmlEncoder, Object)

使用 HTML 编码将指定的 value 写入给定 writer的 。

public:
 static void WriteTo(System::IO::TextWriter ^ writer, System::Text::Encodings::Web::HtmlEncoder ^ encoder, System::Object ^ value);
public static void WriteTo (System.IO.TextWriter writer, System.Text.Encodings.Web.HtmlEncoder encoder, object value);
static member WriteTo : System.IO.TextWriter * System.Text.Encodings.Web.HtmlEncoder * obj -> unit
Public Shared Sub WriteTo (writer As TextWriter, encoder As HtmlEncoder, value As Object)

参数

writer
TextWriter

TextWriter 写入的实例。

encoder
HtmlEncoder

编码 HtmlEncodervalue要使用的 。

value
Object

要写入的 Object

注解

value类型的 IHtmlContent s 是使用 写入的 WriteTo(TextWriter, HtmlEncoder)。 对于所有其他类型, 的ToString()编码结果将写入 。writer

适用于