Attribute
Magento\Catalog\Model\Category\Attribute
What it does
This class represents a category attribute in Magento 2's catalog system, providing getters and setters for attribute properties like visibility, searchability, filtering options, and scope.
Developers use this class when creating, modifying, or retrieving category attribute metadata, such as controlling whether an attribute appears in layered navigation, product listings, or advanced search.
It implements the CategoryAttributeInterface and extends the base entity attribute model.
Public Methods
- getApplyTo()
- setApplyTo()
- getIsWysiwygEnabled()
- setIsWysiwygEnabled()
- getIsHtmlAllowedOnFront()
- setIsHtmlAllowedOnFront()
- getUsedForSortBy()
- setUsedForSortBy()
- getIsFilterable()
- setIsFilterable()
- getIsFilterableInSearch()
- getIsUsedInGrid()
- getIsVisibleInGrid()
- getIsFilterableInGrid()
- setIsFilterableInSearch()
- getPosition()
- setPosition()
- getIsSearchable()
- setIsSearchable()
- getIsVisibleInAdvancedSearch()
- setIsVisibleInAdvancedSearch()
- getIsComparable()
- setIsComparable()
- getIsUsedForPromoRules()
- setIsUsedForPromoRules()
- getIsVisibleOnFront()
- setIsVisibleOnFront()
- getUsedInProductListing()
- setUsedInProductListing()
- getIsVisible()
- setIsVisible()
- getScope()
- setScope()
- setIsUsedInGrid()
- setIsVisibleInGrid()
- setIsFilterableInGrid()