Log in
Model

Result

Magento\Shipping\Model\Rate\Result

What it does

This class serves as a container for shipping rate results during checkout.

Developers use it when implementing shipping carriers or customizing shipping calculations, as it collects, sorts, and manages multiple shipping method rates from different carriers, handles errors, and provides utilities to find the cheapest rate or filter rates by carrier.

Public Methods

  • reset()
  • setError()
  • getError()
  • append()
  • getAllRates()
  • getRateById()
  • getRatesByCarrier()
  • asArray()
  • getCheapestRate()
  • sortRatesByPrice()
  • updateRatePrice()