AbstractCollection
Magento\Eav\Model\Entity\Collection\AbstractCollection
What it does
This abstract collection class serves as the foundation for managing collections of EAV (Entity-Attribute-Value) entities in Magento 2.
Developers extend this class when creating custom collections for entities that use the EAV model, such as products, categories, or customers.
It provides methods for filtering, sorting, and joining attribute data, handling the complexity of loading dynamic EAV attributes alongside static entity fields.
Public Methods
- _resetState()
- getTable()
- setEntity()
- getEntity()
- getResource()
- setObject()
- addItem()
- getAttribute()
- addAttributeToFilter()
- addFieldToFilter()
- addAttributeToSort()
- addAttributeToSelect()
- addEntityTypeToSelect()
- addStaticField()
- addExpressionAttributeToSelect()
- groupByAttribute()
- joinAttribute()
- joinField()
- joinTable()
- removeAttributeToSelect()
- setPage()
- load()
- getAllIds()
- getAllIdsSql()
- save()
- delete()
- importFromArray()
- exportToArray()
- getRowIdFieldName()
- getIdFieldName()
- setRowIdFieldName()
- _loadEntities()
- _loadAttributes()
- setOrder()
- toArray()
- isAttributeAdded()
- getLoadedIds()
- clear()
- removeAllItems()
- removeItemByKey()
- getMainTable()
- addFieldToSelect()
- removeFieldFromSelect()
- removeAllFieldsFromSelect()