<?xml version="1.0" encoding="UTF-8"?>

<!--

 This file is part of the Sylius package.

 (c) Sylius Sp. z o.o.

 For the full copyright and license information, please view the LICENSE
 file that was distributed with this source code.

-->

<container xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://symfony.com/schema/dic/services"
           xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd">
    <services>
        <defaults public="true"/>

        <service id="sylius.category_requirement_shipping_method_eligibility_checker"
                 class="Sylius\Component\Shipping\Checker\Eligibility\CategoryRequirementEligibilityChecker">
            <tag name="sylius.shipping_method_eligibility_checker"/>
        </service>

        <service id="sylius.shipping_method_rules_shipping_method_eligibility_checker"
                 class="Sylius\Component\Shipping\Checker\Eligibility\ShippingMethodRulesEligibilityChecker">
            <argument type="service" id="sylius.registry.shipping_method_rule_checker"/>
            <tag name="sylius.shipping_method_eligibility_checker"/>
        </service>

        <service id="sylius.shipping_method_eligibility_checker"
                 class="Sylius\Component\Shipping\Checker\Eligibility\CompositeShippingMethodEligibilityChecker">
            <argument type="collection"/>
        </service>
        <service id="Sylius\Component\Shipping\Checker\Eligibility\ShippingMethodEligibilityCheckerInterface"
                 alias="sylius.shipping_method_eligibility_checker"/>

        <service id="sylius.shipping_eligibility_checker"
                 class="Sylius\Component\Shipping\Checker\ShippingMethodEligibilityChecker">
            <deprecated package="sylius/sylius" version="1.8">The "%service_id%" is deprecated since Sylius 1.8 and will be removed in 2.0. Use "sylius.shipping_method_eligibility_checker" instead</deprecated>
        </service>
        <service id="Sylius\Component\Shipping\Checker\ShippingMethodEligibilityCheckerInterface"
                 alias="sylius.shipping_method_eligibility_checker"/>
    </services>
</container>
