Image
Magento\Catalog\Model\ProductRender\Image
What it does
This class represents a product image data model used for rendering product images in various contexts like product listings, detail pages, and API responses.
Developers use it to access and manage image properties such as URL, dimensions (original and resized), label, and unique code identifier.
It's typically populated by image renderers and consumed by frontend templates or API endpoints that need structured image data.
Public Methods
- setUrl()
- getUrl()
- getCode()
- setCode()
- setHeight()
- getHeight()
- getWidth()
- setWidth()
- getLabel()
- setLabel()
- getResizedWidth()
- setResizedWidth()
- setResizedHeight()
- getResizedHeight()
- getExtensionAttributes()
- setExtensionAttributes()