6 instantiations of ViewComponentResult
Microsoft.AspNetCore.Mvc.RazorPages (4)
PageBase.cs (2)
1237
return new
ViewComponentResult
1259
return new
ViewComponentResult
PageModel.cs (2)
1595
return new
ViewComponentResult
1617
return new
ViewComponentResult
Microsoft.AspNetCore.Mvc.ViewFeatures (2)
Controller.cs (2)
249
return new
ViewComponentResult
272
return new
ViewComponentResult
46 references to ViewComponentResult
Microsoft.AspNetCore.Mvc.RazorPages (24)
PageBase.cs (12)
1199
/// Creates a <see cref="
ViewComponentResult
"/> by specifying the name of a view component to render.
1205
/// <returns>The created <see cref="
ViewComponentResult
"/> object for the response.</returns>
1206
public virtual
ViewComponentResult
ViewComponent(string componentName)
1212
/// Creates a <see cref="
ViewComponentResult
"/> by specifying the <see cref="Type"/> of a view component to
1216
/// <returns>The created <see cref="
ViewComponentResult
"/> object for the response.</returns>
1217
public virtual
ViewComponentResult
ViewComponent(Type componentType)
1223
/// Creates a <see cref="
ViewComponentResult
"/> by specifying the name of a view component to render.
1234
/// <returns>The created <see cref="
ViewComponentResult
"/> object for the response.</returns>
1235
public virtual
ViewComponentResult
ViewComponent(string componentName, object? arguments)
1247
/// Creates a <see cref="
ViewComponentResult
"/> by specifying the <see cref="Type"/> of a view component to
1256
/// <returns>The created <see cref="
ViewComponentResult
"/> object for the response.</returns>
1257
public virtual
ViewComponentResult
ViewComponent(Type componentType, object? arguments)
PageModel.cs (12)
1557
/// Creates a <see cref="
ViewComponentResult
"/> by specifying the name of a view component to render.
1563
/// <returns>The created <see cref="
ViewComponentResult
"/> object for the response.</returns>
1564
public virtual
ViewComponentResult
ViewComponent(string componentName)
1570
/// Creates a <see cref="
ViewComponentResult
"/> by specifying the <see cref="Type"/> of a view component to
1574
/// <returns>The created <see cref="
ViewComponentResult
"/> object for the response.</returns>
1575
public virtual
ViewComponentResult
ViewComponent(Type componentType)
1581
/// Creates a <see cref="
ViewComponentResult
"/> by specifying the name of a view component to render.
1592
/// <returns>The created <see cref="
ViewComponentResult
"/> object for the response.</returns>
1593
public virtual
ViewComponentResult
ViewComponent(string componentName, object? arguments)
1605
/// Creates a <see cref="
ViewComponentResult
"/> by specifying the <see cref="Type"/> of a view component to
1614
/// <returns>The created <see cref="
ViewComponentResult
"/> object for the response.</returns>
1615
public virtual
ViewComponentResult
ViewComponent(Type componentType, object? arguments)
Microsoft.AspNetCore.Mvc.ViewFeatures (22)
Controller.cs (12)
208
/// Creates a <see cref="
ViewComponentResult
"/> by specifying the name of a view component to render.
214
/// <returns>The created <see cref="
ViewComponentResult
"/> object for the response.</returns>
216
public virtual
ViewComponentResult
ViewComponent(string componentName)
222
/// Creates a <see cref="
ViewComponentResult
"/> by specifying the <see cref="Type"/> of a view component to
226
/// <returns>The created <see cref="
ViewComponentResult
"/> object for the response.</returns>
228
public virtual
ViewComponentResult
ViewComponent(Type componentType)
234
/// Creates a <see cref="
ViewComponentResult
"/> by specifying the name of a view component to render.
245
/// <returns>The created <see cref="
ViewComponentResult
"/> object for the response.</returns>
247
public virtual
ViewComponentResult
ViewComponent(string componentName, object? arguments)
259
/// Creates a <see cref="
ViewComponentResult
"/> by specifying the <see cref="Type"/> of a view component to
268
/// <returns>The created <see cref="
ViewComponentResult
"/> object for the response.</returns>
270
public virtual
ViewComponentResult
ViewComponent(Type componentType, object? arguments)
DependencyInjection\MvcViewFeaturesMvcCoreBuilderExtensions.cs (1)
177
services.TryAddSingleton<IActionResultExecutor<
ViewComponentResult
>, ViewComponentResultExecutor>();
ViewComponentResult.cs (1)
64
var executor = services.GetService<IActionResultExecutor<
ViewComponentResult
>>();
ViewComponentResultExecutor.cs (8)
24
/// A <see cref="IActionResultExecutor{ViewComponentResult}"/> for <see cref="
ViewComponentResult
"/>.
26
public partial class ViewComponentResultExecutor : IActionResultExecutor<
ViewComponentResult
>
30
private readonly ILogger<
ViewComponentResult
> _logger;
59
_logger = loggerFactory.CreateLogger<
ViewComponentResult
>();
67
public virtual async Task ExecuteAsync(ActionContext context,
ViewComponentResult
result)
142
private static Task<IHtmlContent> GetViewComponentResult(IViewComponentHelper viewComponentHelper, ILogger logger,
ViewComponentResult
result)
147
nameof(
ViewComponentResult
.ViewComponentName),
148
nameof(
ViewComponentResult
.ViewComponentType)));