Overview

Namespaces

  • Apptus
    • ESales
      • Connector
        • Report
        • Time
    • Util
      • Cache
  • PHP

Classes

  • Ad
  • Ads
  • ArgMap
  • Attribute
  • AttributeValidation
  • Authorization
  • Category
  • CategoryData
  • CategoryList
  • CategoryNode
  • CloudConnector
  • ClusterUriIterator
  • Completion
  • Completions
  • CompressionMode
  • Connector
  • ConnectorSettingsBuilder
  • Correction
  • Corrections
  • Count
  • CssClass
  • CustomerKeyAuthentication
  • DynamicPage
  • EventDataJobResult
  • FacetList
  • FacetRange
  • Facets
  • Filter
  • FilterBuilder
  • ImportData
  • JavaScriptNotifier
  • MessageAuthentication
  • OnPremConnector
  • Order
  • OrderLine
  • Panel
  • PanelContent
  • Path
  • Phrase
  • Phrases
  • Product
  • Products
  • Reporter
  • ResultType
  • Session
  • Status
  • Subpanel
  • Value
  • Values
  • Variant

Interfaces

  • Facet
  • Result

Exceptions

  • BusyClusterException
  • ClusterUnavailableException
  • DuplicateSubpanelException
  • FetchClusterException
  • IOException
  • MalformedJsonException
  • MalformedURLException
  • MissingSubpanelException
  • PanelException
  • ParseException
  • ReportException
  • RequestFailedException
  • ResultTypeException
  • Overview
  • Namespace
  • Class
  • Tree

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
Extended by Apptus\ESales\Connector\CategoryNode implements Apptus\ESales\Connector\Result, IteratorAggregate
Namespace: Apptus\ESales\Connector
Package: Apptus\ESales\Connector
Located at Connector/CategoryNode.php
Methods summary
public array
# getSubcategories( )

Get a list of this category's subcategories.

Get a list of this category's subcategories.

Returns

array
the subcategories
public Apptus\ESales\Connector\CategoryNode
# getSelectedSubcategory( )

Get the selected category among this category's subcategories, or null if none is selected.

Get the selected category among this category's subcategories, or null if none is selected.

Returns

Apptus\ESales\Connector\CategoryNode
the selected subcategory, or null
public Apptus\ESales\Connector\CategoryNode
# findDescendant( string $categoryKey )

Searches for the specified category key among this category and its descendants. Returns null if the category key was not found.

Searches for the specified category key among this category and its descendants. Returns null if the category key was not found.

Parameters

$categoryKey
the key of the category to search for

Returns

Apptus\ESales\Connector\CategoryNode
the found CategoryNode with key $categoryKey, or null
public Apptus\ESales\Connector\CategoryNode
# getParent( )

Get the parent of this category.

Get the parent of this category.

Returns

Apptus\ESales\Connector\CategoryNode
the parent of this category
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)

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)

Returns

boolean
true if this category is selected
public string
# getType( )

Get the result type of this result.

Get the result type of this result.

Returns

string
The result type

See

Apptus\ESales\Connector\ResultType

Implementation of

Apptus\ESales\Connector\Result::getType()
Methods inherited from Apptus\ESales\Connector\Category
__toString(), addSpecialAttribute(), getAttribute(), getDisplayName(), getIterator(), getLocale(), getParentKey(), getProductCount(), getTicket(), getValue(), key()
Apptus ESales Connector PHP API documentation generated by ApiGen