public DefaultViewComponentHelper( [NotNull] IViewComponentSelector selector, [NotNull] IViewComponentInvokerFactory invokerFactory) { _selector = selector; _invokerFactory = invokerFactory; }
public DefaultViewComponentHelper( [NotNull] IViewComponentDescriptorCollectionProvider descriptorProvider, [NotNull] IViewComponentSelector selector, [NotNull] IViewComponentInvokerFactory invokerFactory) { _descriptorProvider = descriptorProvider; _selector = selector; _invokerFactory = invokerFactory; }
/// <summary> /// Initializes a new instance of <see cref="DefaultViewComponentHelper"/>. /// </summary> /// <param name="descriptorProvider">The <see cref="IViewComponentDescriptorCollectionProvider"/> /// used to locate view components.</param> /// <param name="htmlEncoder">The <see cref="HtmlEncoder"/>.</param> /// <param name="selector">The <see cref="IViewComponentSelector"/>.</param> /// <param name="invokerFactory">The <see cref="IViewComponentInvokerFactory"/>.</param> /// <param name="viewBufferScope">The <see cref="IViewBufferScope"/> that manages the lifetime of /// <see cref="ViewBuffer"/> instances.</param> public DefaultViewComponentHelper( IViewComponentDescriptorCollectionProvider descriptorProvider, HtmlEncoder htmlEncoder, IViewComponentSelector selector, IViewComponentInvokerFactory invokerFactory, #pragma warning disable PUB0001 // Pubternal type in public API IViewBufferScope viewBufferScope #pragma warning restore PUB0001 ) { if (descriptorProvider == null) { throw new ArgumentNullException(nameof(descriptorProvider)); } if (htmlEncoder == null) { throw new ArgumentNullException(nameof(htmlEncoder)); } if (selector == null) { throw new ArgumentNullException(nameof(selector)); } if (invokerFactory == null) { throw new ArgumentNullException(nameof(invokerFactory)); } if (viewBufferScope == null) { throw new ArgumentNullException(nameof(viewBufferScope)); } _descriptorProvider = descriptorProvider; _htmlEncoder = htmlEncoder; _selector = selector; _invokerFactory = invokerFactory; _viewBufferScope = viewBufferScope; }
/// <summary> /// Initializes a new instance of <see cref="DefaultViewComponentHelper"/>. /// </summary> /// <param name="descriptorProvider">The <see cref="IViewComponentDescriptorCollectionProvider"/> /// used to locate view components.</param> /// <param name="htmlEncoder">The <see cref="HtmlEncoder"/>.</param> /// <param name="selector">The <see cref="IViewComponentSelector"/>.</param> /// <param name="invokerFactory">The <see cref="IViewComponentInvokerFactory"/>.</param> /// <param name="viewBufferScope">The <see cref="IViewBufferScope"/> that manages the lifetime of /// <see cref="ViewBuffer"/> instances.</param> public DefaultViewComponentHelper( IViewComponentDescriptorCollectionProvider descriptorProvider, HtmlEncoder htmlEncoder, IViewComponentSelector selector, IViewComponentInvokerFactory invokerFactory, IViewBufferScope viewBufferScope ) { if (descriptorProvider == null) { throw new ArgumentNullException(nameof(descriptorProvider)); } if (htmlEncoder == null) { throw new ArgumentNullException(nameof(htmlEncoder)); } if (selector == null) { throw new ArgumentNullException(nameof(selector)); } if (invokerFactory == null) { throw new ArgumentNullException(nameof(invokerFactory)); } if (viewBufferScope == null) { throw new ArgumentNullException(nameof(viewBufferScope)); } _descriptorProvider = descriptorProvider; _htmlEncoder = htmlEncoder; _selector = selector; _invokerFactory = invokerFactory; _viewBufferScope = viewBufferScope; }
/// <summary> /// Initializes a new instance of <see cref="DefaultViewComponentHelper"/>. /// </summary> /// <param name="descriptorProvider">The <see cref="IViewComponentDescriptorCollectionProvider"/> /// used to locate view components.</param> /// <param name="htmlEncoder">The <see cref="HtmlEncoder"/>.</param> /// <param name="selector">The <see cref="IViewComponentSelector"/>.</param> /// <param name="invokerFactory">The <see cref="IViewComponentInvokerFactory"/>.</param> /// <param name="viewBufferScope">The <see cref="IViewBufferScope"/> that manages the lifetime of /// <see cref="ViewBuffer"/> instances.</param> public DefaultViewComponentHelper( IViewComponentDescriptorCollectionProvider descriptorProvider, HtmlEncoder htmlEncoder, IViewComponentSelector selector, IViewComponentInvokerFactory invokerFactory, IViewBufferScope viewBufferScope) { if (descriptorProvider == null) { throw new ArgumentNullException(nameof(descriptorProvider)); } if (htmlEncoder == null) { throw new ArgumentNullException(nameof(htmlEncoder)); } if (selector == null) { throw new ArgumentNullException(nameof(selector)); } if (invokerFactory == null) { throw new ArgumentNullException(nameof(invokerFactory)); } if (viewBufferScope == null) { throw new ArgumentNullException(nameof(viewBufferScope)); } _descriptorProvider = descriptorProvider; _htmlEncoder = htmlEncoder; _selector = selector; _invokerFactory = invokerFactory; _viewBufferScope = viewBufferScope; }
public DefaultViewComponentHelper( IViewComponentDescriptorCollectionProvider descriptorProvider, IViewComponentSelector selector, IViewComponentInvokerFactory invokerFactory) { if (descriptorProvider == null) { throw new ArgumentNullException(nameof(descriptorProvider)); } if (selector == null) { throw new ArgumentNullException(nameof(selector)); } if (invokerFactory == null) { throw new ArgumentNullException(nameof(invokerFactory)); } _descriptorProvider = descriptorProvider; _selector = selector; _invokerFactory = invokerFactory; }
public WidgetViewComponentInvokerFactory(IViewComponentInvokerFactory defaultFactory) { _defaultFactory = defaultFactory; this._scope = new WidgetContextScope(); }