TotalsAdditionalData
Magento\Quote\Model\Cart\TotalsAdditionalData
What it does
This class serves as a data container for additional information related to shopping cart totals in Magento 2.
It implements the TotalsAdditionalDataInterface and provides extension attributes functionality, allowing developers to attach custom data to cart total calculations without modifying core code.
Use this when you need to pass extra information alongside cart totals through the API or extend totals data with custom attributes.
Public Methods
- getExtensionAttributes()
- setExtensionAttributes()