<?xml version="1.0" ?>

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

    <services>
        <service id="Shopware\Core\System\StateMachine\Api\StateMachineActionController" public="true">
            <argument type="service" id="Shopware\Core\System\StateMachine\StateMachineRegistry"/>
            <argument type="service" id="Shopware\Core\Framework\DataAbstractionLayer\DefinitionInstanceRegistry"/>
            <call method="setContainer">
                <argument type="service" id="service_container"/>
            </call>
        </service>

        <service id="Shopware\Core\System\StateMachine\StateMachineRegistry">
            <argument type="service" id="state_machine.repository" />
            <argument type="service" id="state_machine_state.repository" />
            <argument type="service" id="state_machine_history.repository" />
            <argument type="service" id="event_dispatcher"/>
            <argument type="service" id="Shopware\Core\Framework\DataAbstractionLayer\DefinitionInstanceRegistry"/>

            <tag name="kernel.reset" method="reset"/>
        </service>

        <service id="Shopware\Core\System\StateMachine\Command\WorkflowDumpCommand">
            <argument type="service" id="Shopware\Core\System\StateMachine\StateMachineRegistry"/>

            <tag name="console.command"/>
        </service>
        <service id="Shopware\Core\System\StateMachine\StateMachineDefinition">
            <tag name="shopware.entity.definition"/>
        </service>
        <service id="Shopware\Core\System\StateMachine\StateMachineTranslationDefinition">
            <tag name="shopware.entity.definition"/>
        </service>
        <service id="Shopware\Core\System\StateMachine\Aggregation\StateMachineState\StateMachineStateDefinition">
            <tag name="shopware.entity.definition"/>
        </service>
        <service id="Shopware\Core\System\StateMachine\Aggregation\StateMachineState\StateMachineStateTranslationDefinition">
            <tag name="shopware.entity.definition"/>
        </service>
        <service  id="Shopware\Core\System\StateMachine\Aggregation\StateMachineTransition\StateMachineTransitionDefinition">
            <tag name="shopware.entity.definition"/>
        </service>
        <service  id="Shopware\Core\System\StateMachine\Aggregation\StateMachineHistory\StateMachineHistoryDefinition">
            <tag name="shopware.entity.definition"/>
        </service>

        <service id="Shopware\Core\System\StateMachine\Loader\InitialStateIdLoader">
            <argument type="service" id="Doctrine\DBAL\Connection"/>
            <argument type="service" id="cache.object"/>
            <tag name="kernel.reset" method="reset"/>
        </service>
    </services>
</container>
