Class NodeContentExtensions

Extension methods for NodeContent.

Inheritance
System.Object
NodeContentExtensions
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: EPiServer.Commerce.Catalog.ContentTypes
Assembly: EPiServer.Business.Commerce.dll
Version: 10.8.0
Syntax
public static class NodeContentExtensions

Methods

GetCategories(NodeContent)

Gets the categories to which the category is linked (parent categories). N.B. This does not include the main parent category (given by the ParentLink of the content).

Declaration
public static IEnumerable<ContentReference> GetCategories(this NodeContent node)
Parameters
Type Name Description
NodeContent node

The node.

Returns
Type Description
System.Collections.Generic.IEnumerable<EPiServer.Core.ContentReference>

EPiServer.Core.ContentReferences of the parent categories.

GetCategories(NodeContent, IRelationRepository)

Gets the categories to which the category is linked (parent categories). N.B. This does not include the main parent category (given by the ParentLink of the content).

Declaration
public static IEnumerable<ContentReference> GetCategories(this NodeContent node, IRelationRepository relationRepository)
Parameters
Type Name Description
NodeContent node

The node.

IRelationRepository relationRepository

The relation repository.

Returns
Type Description
System.Collections.Generic.IEnumerable<EPiServer.Core.ContentReference>

EPiServer.Core.ContentReferences of the parent categories.

LoadNode(NodeContent)

Gets the CatalogNode for the content with CatalogNodeFull.

Declaration
public static CatalogNode LoadNode(this NodeContent content)
Parameters
Type Name Description
NodeContent content

The content

Returns
Type Description
CatalogNode

The NodeContent representing the same data as the instance.

Remarks

ICatalogSystem will be used to load the node. This might result in database round trips.

LoadNode(NodeContent, CatalogNodeResponseGroup.ResponseGroup)

Gets the CatalogNode for the content.

Declaration
public static CatalogNode LoadNode(this NodeContent content, CatalogNodeResponseGroup.ResponseGroup responseGroup)
Parameters
Type Name Description
NodeContent content

The content

CatalogNodeResponseGroup.ResponseGroup responseGroup

The response group, that will be used when loading hte catalog node.

Returns
Type Description
CatalogNode

The NodeContent representing the same data as the instance.

Remarks

ICatalogSystem will be used to load the node. This might result in database round trips.

LoadNode(NodeContent, CatalogNodeResponseGroup.ResponseGroup, ICatalogSystem)

Gets the CatalogNode for the content.

Declaration
public static CatalogNode LoadNode(this NodeContent content, CatalogNodeResponseGroup.ResponseGroup responseGroup, ICatalogSystem catalogSystem)
Parameters
Type Name Description
NodeContent content

The content

CatalogNodeResponseGroup.ResponseGroup responseGroup

The response group, that will be used when loading hte catalog node.

ICatalogSystem catalogSystem

The catalog system

Returns
Type Description
CatalogNode

The NodeContent representing the same data as the instance.

Remarks

ICatalogSystem will be used to load the node. This might result in database round trips.