TagHelperOutput 构造函数

定义

实例化 TagHelperOutput 的新实例。

public:
 TagHelperOutput(System::String ^ tagName, Microsoft::AspNetCore::Razor::TagHelpers::TagHelperAttributeList ^ attributes, Func<bool, System::Text::Encodings::Web::HtmlEncoder ^, System::Threading::Tasks::Task<Microsoft::AspNetCore::Razor::TagHelpers::TagHelperContent ^> ^> ^ getChildContentAsync);
public TagHelperOutput (string tagName, Microsoft.AspNetCore.Razor.TagHelpers.TagHelperAttributeList attributes, Func<bool,System.Text.Encodings.Web.HtmlEncoder,System.Threading.Tasks.Task<Microsoft.AspNetCore.Razor.TagHelpers.TagHelperContent>> getChildContentAsync);
new Microsoft.AspNetCore.Razor.TagHelpers.TagHelperOutput : string * Microsoft.AspNetCore.Razor.TagHelpers.TagHelperAttributeList * Func<bool, System.Text.Encodings.Web.HtmlEncoder, System.Threading.Tasks.Task<Microsoft.AspNetCore.Razor.TagHelpers.TagHelperContent>> -> Microsoft.AspNetCore.Razor.TagHelpers.TagHelperOutput
Public Sub New (tagName As String, attributes As TagHelperAttributeList, getChildContentAsync As Func(Of Boolean, HtmlEncoder, Task(Of TagHelperContent)))

参数

tagName
String

HTML 元素的标记名称。

attributes
TagHelperAttributeList

HTML 特性。

getChildContentAsync
Func<Boolean,HtmlEncoder,Task<TagHelperContent>>

一个委托,用于在范围内使用给定 HtmlEncoder 的 异步执行子级,并返回其呈现的内容。

适用于