Class PartialContentComponent<TContentData>
Provides the base implementation for synchronous partial content components.
Inheritance
System.Object
PartialContentComponent<TContentData>
Namespace: EPiServer.Web.Mvc
Assembly: EPiServer.Cms.AspNetCore.Mvc.dll
Version: 12.0.3Syntax
[VisitorGroupImpersonation]
public abstract class PartialContentComponent<TContentData> : ViewComponent, IRenderTemplate<TContentData>, IRenderTemplate where TContentData : IContentData
Type Parameters
Name | Description |
---|---|
TContentData | The type of the content data. |
Constructors
PartialContentComponent()
Declaration
protected PartialContentComponent()
Methods
Invoke(TContentData)
Mandatory method for synchronous view components. Will call method Invoke
Declaration
public IViewComponentResult Invoke(TContentData currentContent)
Parameters
Type | Name | Description |
---|---|---|
TContent |
currentContent | The current content instance. |
Returns
Type | Description |
---|---|
Microsoft. |
Content from the view |
InvokeComponent(TContentData)
Method that component should implement to render currentContent
Declaration
protected abstract IViewComponentResult InvokeComponent(TContentData currentContent)
Parameters
Type | Name | Description |
---|---|---|
TContent |
currentContent | The current content instance. |
Returns
Type | Description |
---|---|
Microsoft. |
The result from the component |