Log in
Model

Context

Magento\Catalog\Model\Layer\Context

What it does

This Context class serves as a dependency container for the Magento Catalog Layer, grouping related dependencies like collection providers, state keys, and collection filters.

It follows the Context Object pattern to allow backward-compatible constructor modifications without breaking extensions that extend the Layer class.

Developers typically don't interact with this class directly but receive it as a constructor dependency when working with catalog layers.

Public Methods

  • getCollectionProvider()
  • getStateKey()
  • getCollectionFilter()