Log in
Model

AbstractFilter

Magento\Catalog\Model\Layer\Filter\AbstractFilter

What it does

This abstract base class provides core functionality for layered navigation filters in Magento 2 catalog pages.

Developers extend this class to create custom filters (like price, category, or attribute filters) that allow customers to narrow down product searches.

It manages filter items, handles filter application to product collections, and provides methods for rendering filter options in the frontend.

Public Methods

  • setRequestVar()
  • getRequestVar()
  • getResetValue()
  • getCleanValue()
  • apply()
  • getItemsCount()
  • getItems()
  • setItems()
  • getLayer()
  • setAttributeModel()
  • getAttributeModel()
  • getName()
  • getStoreId()
  • setStoreId()
  • getWebsiteId()
  • setWebsiteId()
  • getClearLinkText()