Freigeben über


TagHelperExecutionContext Konstruktor

Definition

Instanziiert eine neue TagHelperExecutionContext.

public:
 TagHelperExecutionContext(System::String ^ tagName, Microsoft::AspNetCore::Razor::TagHelpers::TagMode tagMode, System::Collections::Generic::IDictionary<System::Object ^, System::Object ^> ^ items, System::String ^ uniqueId, Func<System::Threading::Tasks::Task ^> ^ executeChildContentAsync, Action<System::Text::Encodings::Web::HtmlEncoder ^> ^ startTagHelperWritingScope, Func<Microsoft::AspNetCore::Razor::TagHelpers::TagHelperContent ^> ^ endTagHelperWritingScope);
public TagHelperExecutionContext (string tagName, Microsoft.AspNetCore.Razor.TagHelpers.TagMode tagMode, System.Collections.Generic.IDictionary<object,object> items, string uniqueId, Func<System.Threading.Tasks.Task> executeChildContentAsync, Action<System.Text.Encodings.Web.HtmlEncoder> startTagHelperWritingScope, Func<Microsoft.AspNetCore.Razor.TagHelpers.TagHelperContent> endTagHelperWritingScope);
new Microsoft.AspNetCore.Razor.Runtime.TagHelpers.TagHelperExecutionContext : string * Microsoft.AspNetCore.Razor.TagHelpers.TagMode * System.Collections.Generic.IDictionary<obj, obj> * string * Func<System.Threading.Tasks.Task> * Action<System.Text.Encodings.Web.HtmlEncoder> * Func<Microsoft.AspNetCore.Razor.TagHelpers.TagHelperContent> -> Microsoft.AspNetCore.Razor.Runtime.TagHelpers.TagHelperExecutionContext
Public Sub New (tagName As String, tagMode As TagMode, items As IDictionary(Of Object, Object), uniqueId As String, executeChildContentAsync As Func(Of Task), startTagHelperWritingScope As Action(Of HtmlEncoder), endTagHelperWritingScope As Func(Of TagHelperContent))

Parameter

tagName
String

Der NAME des HTML-Tags in der Razor-Quelle.

tagMode
TagMode

HTML-Syntax des Elements in der Razor-Quelle.

items
IDictionary<Object,Object>

Die Auflistung der Elemente, die für die Kommunikation mit anderen ITagHelperElementen verwendet werden

uniqueId
String

Ein Bezeichner, der für das HTML-Element eindeutig ist, für das dieser Kontext gilt.

executeChildContentAsync
Func<Task>

Ein Delegat, der zum asynchronen Ausführen des untergeordneten Inhalts verwendet wird.

startTagHelperWritingScope
Action<HtmlEncoder>

Ein Delegat, der verwendet wird, um einen Schreibbereich auf einer Razor-Seite zu starten und optional die Seite innerhalb dieses Bereichs HtmlEncoder außer Kraft zu setzen.

endTagHelperWritingScope
Func<TagHelperContent>

Ein Delegat, der verwendet wird, um einen Schreibbereich auf einer Razor-Seite zu beenden.

Gilt für: