Related
Magento\Catalog\Model\ProductLink\CollectionProvider\Related
What it does
This class is a collection provider that retrieves related products for a given product in Magento 2.
Developers would use this when they need to programmatically fetch products that are linked as 'related products' to display them on product pages, in widgets, or custom functionality.
It implements the CollectionProviderInterface to standardize how related product collections are retrieved throughout the system.
Public Methods
- getLinkedProducts()