Interface
ButtonInterface
Magento\Catalog\Api\Data\ProductRender\ButtonInterface
What it does
This interface defines the contract for product action buttons in Magento 2's product rendering system, such as 'Add to Cart', 'Add to Compare', or 'Add to Wishlist' buttons.
Developers use this interface when working with product listing/detail pages to configure button behavior, URLs, POST data for backend actions, and whether required product options must be selected before the action can be performed.
Public Methods
- setPostData()
- getPostData()
- setUrl()
- getUrl()
- setRequiredOptions()
- hasRequiredOptions()
- getExtensionAttributes()
- setExtensionAttributes()