1 implementation of IViewComponentHelper
Microsoft.AspNetCore.Mvc.ViewFeatures (1)
ViewComponents\DefaultViewComponentHelper.cs (1)
19
public class DefaultViewComponentHelper :
IViewComponentHelper
, IViewContextAware
27 references to IViewComponentHelper
Microsoft.AspNetCore.Mvc.RazorPages.Test (2)
ApplicationModels\DefaultPageApplicationModelProviderTest.cs (2)
492
public global::Microsoft.AspNetCore.Mvc.
IViewComponentHelper
Component { get; private set; }
514
public global::Microsoft.AspNetCore.Mvc.
IViewComponentHelper
Component { get; private set; }
Microsoft.AspNetCore.Mvc.ViewFeatures (14)
DependencyInjection\MvcViewFeaturesMvcCoreBuilderExtensions.cs (1)
182
services.TryAddTransient<
IViewComponentHelper
, DefaultViewComponentHelper>();
Rendering\ViewComponentHelperExtensions.cs (9)
11
/// Extension methods for <see cref="
IViewComponentHelper
"/>.
18
/// <param name="helper">The <see cref="
IViewComponentHelper
"/>.</param>
22
public static Task<IHtmlContent> InvokeAsync(this
IViewComponentHelper
helper, string name)
32
/// <param name="helper">The <see cref="
IViewComponentHelper
"/>.</param>
36
public static Task<IHtmlContent> InvokeAsync(this
IViewComponentHelper
helper, Type componentType)
46
/// <param name="helper">The <see cref="
IViewComponentHelper
"/>.</param>
51
public static Task<IHtmlContent> InvokeAsync<TComponent>(this
IViewComponentHelper
helper, object? arguments)
61
/// <param name="helper">The <see cref="
IViewComponentHelper
"/>.</param>
65
public static Task<IHtmlContent> InvokeAsync<TComponent>(this
IViewComponentHelper
helper)
ViewComponentResultExecutor.cs (3)
113
var
viewComponentHelper = context.HttpContext.RequestServices.GetRequiredService<
IViewComponentHelper
>();
142
private static Task<IHtmlContent> GetViewComponentResult(
IViewComponentHelper
viewComponentHelper, ILogger logger, ViewComponentResult result)
ViewComponents\DefaultViewComponentHelper.cs (1)
17
/// Default implementation for <see cref="
IViewComponentHelper
"/>.
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (8)
Rendering\DefaultTemplatesUtilities.cs (1)
272
.AddSingleton(Mock.Of<
IViewComponentHelper
>())
ViewComponentResultTest.cs (7)
410
var
helper = Mock.Of<
IViewComponentHelper
>(h => h.InvokeAsync(It.IsAny<Type>(), It.IsAny<object>()) == result);
414
services.AddSingleton<
IViewComponentHelper
>(helper);
452
var
helper = Mock.Of<
IViewComponentHelper
>(h => h.InvokeAsync(It.IsAny<Type>(), It.IsAny<object>()) == result);
456
services.AddSingleton<
IViewComponentHelper
>(helper);
665
services.AddTransient<
IViewComponentHelper
, DefaultViewComponentHelper>();
RazorBuildWebSite.Views (3)
Pages\Rzc\Page.cs (1)
32
public global::Microsoft.AspNetCore.Mvc.
IViewComponentHelper
Component { get; private set; }
Views\Common\CommonView.cs (1)
32
public global::Microsoft.AspNetCore.Mvc.
IViewComponentHelper
Component { get; private set; }
Views\Rzc\View.cs (1)
32
public global::Microsoft.AspNetCore.Mvc.
IViewComponentHelper
Component { get; private set; }