Class CategoryNode
Represents a result having the category_tree format. A CategoryNode is part of a category tree and may, in addition to attributes, have a parent and/or subcategories. The tree can be traversed using for example CategoryNode.getSubcategories(), or utility methods such as CategoryNode.getSelectedSubcategory() and CategoryNode.findDescendant(key).
- Apptus\ESales\Connector\Category implements IteratorAggregate
- Apptus\ESales\Connector\CategoryNode implements Apptus\ESales\Connector\Result, IteratorAggregate
Namespace: Apptus\ESales\Connector
Package: Apptus\ESales\Connector
Located at Connector/CategoryNode.php
Package: Apptus\ESales\Connector
Located at Connector/CategoryNode.php
public
array
|
|
public
|
#
getSelectedSubcategory( )
Get the selected category among this category's subcategories, or null if none is selected. |
public
|
#
findDescendant( string $categoryKey )
Searches for the specified category key among this category and its descendants. Returns null if the category key was not found. |
public
|
|
public
boolean
|
#
isSelected( )
Check if this category is a selected category. Returns true if the category is selected (or if the category is an ancestor to a selected category) |
public
string
|
__toString(),
addSpecialAttribute(),
getAttribute(),
getDisplayName(),
getIterator(),
getLocale(),
getParentKey(),
getProductCount(),
getTicket(),
getValue(),
key()
|