Service/ShippingMethodHandler.php
protected function getAvailableShipmentMethods(Shipment $shipment, CountryInterface $country)
    {
        $weight = $shipment->getWeight();
        $shipmentMethods = $this->shipmentMethodRepository->findForCheckout($country, $weight);

        if (count($this->shipmentMethods) === 0) {
            $this->shipmentMethods = $shipmentMethods;
        } else {
            //TODO virer ceux qu'on ne peut pas utiliser
        }

        return $this->shipmentMethods;
    }
protected function getAvailableShipmentMethods(Shipment $shipment, CountryInterface $country)
    {
        $weight = $shipment->getWeight();
        $shipmentMethods = $this->shipmentMethodRepository->findForCheckout($country, $weight);

        if (count($this->shipmentMethods) === 0) {
            $this->shipmentMethods = $shipmentMethods;
        } else {
            //TODO virer ceux qu'on ne peut pas utiliser
        }

        return $this->shipmentMethods;
    }
@param Shipment         $shipment
@param CountryInterface $country

@return array