Dela via


DefaultViewComponentHelper.InvokeAsync Method

Definition

Overloads

InvokeAsync(String, Object)

Invokes a view component with the specified name.

InvokeAsync(Type, Object)

Invokes a view component of type componentType.

InvokeAsync(String, Object)

Source:
DefaultViewComponentHelper.cs
Source:
DefaultViewComponentHelper.cs
Source:
DefaultViewComponentHelper.cs

Invokes a view component with the specified name.

public:
 virtual System::Threading::Tasks::Task<Microsoft::AspNetCore::Html::IHtmlContent ^> ^ InvokeAsync(System::String ^ name, System::Object ^ arguments);
public System.Threading.Tasks.Task<Microsoft.AspNetCore.Html.IHtmlContent> InvokeAsync (string name, object arguments);
public System.Threading.Tasks.Task<Microsoft.AspNetCore.Html.IHtmlContent> InvokeAsync (string name, object? arguments);
abstract member InvokeAsync : string * obj -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Html.IHtmlContent>
override this.InvokeAsync : string * obj -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Html.IHtmlContent>
Public Function InvokeAsync (name As String, arguments As Object) As Task(Of IHtmlContent)

Parameters

name
String

The name of the view component.

arguments
Object

An Object with properties representing arguments to be passed to the invoked view component method. Alternatively, an IDictionary<TKey,TValue> instance containing the invocation arguments.

Returns

A Task that on completion returns the rendered IHtmlContent.

Implements

Applies to

InvokeAsync(Type, Object)

Source:
DefaultViewComponentHelper.cs
Source:
DefaultViewComponentHelper.cs
Source:
DefaultViewComponentHelper.cs

Invokes a view component of type componentType.

public:
 virtual System::Threading::Tasks::Task<Microsoft::AspNetCore::Html::IHtmlContent ^> ^ InvokeAsync(Type ^ componentType, System::Object ^ arguments);
public System.Threading.Tasks.Task<Microsoft.AspNetCore.Html.IHtmlContent> InvokeAsync (Type componentType, object arguments);
public System.Threading.Tasks.Task<Microsoft.AspNetCore.Html.IHtmlContent> InvokeAsync (Type componentType, object? arguments);
abstract member InvokeAsync : Type * obj -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Html.IHtmlContent>
override this.InvokeAsync : Type * obj -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Html.IHtmlContent>
Public Function InvokeAsync (componentType As Type, arguments As Object) As Task(Of IHtmlContent)

Parameters

componentType
Type

The view component Type.

arguments
Object

An Object with properties representing arguments to be passed to the invoked view component method. Alternatively, an IDictionary<TKey,TValue> instance containing the invocation arguments.

Returns

A Task that on completion returns the rendered IHtmlContent.

Implements

Applies to