imports:
  - { resource: ../common.yml }
  - { resource: api.yml }
  - { resource: decorator.yml }
  - { resource: provider.yml }
  - { resource: repository.yml }
  - { resource: builder.yml }
  - { resource: context.yml }

services:
  PrestaShop\Module\PsEventbus\Formatter\JsonFormatter:
    class: PrestaShop\Module\PsEventbus\Formatter\JsonFormatter
    public: true

  PrestaShop\Module\PsEventbus\Formatter\ArrayFormatter:
    class: PrestaShop\Module\PsEventbus\Formatter\ArrayFormatter
    public: true

  PrestaShop\Module\PsEventbus\Service\CacheService:
    class: PrestaShop\Module\PsEventbus\Service\CacheService
    public: true

  PrestaShop\Module\PsEventbus\Service\CompressionService:
    class: PrestaShop\Module\PsEventbus\Service\CompressionService
    public: true
    arguments:
      - '@PrestaShop\Module\PsEventbus\Formatter\JsonFormatter'

  PrestaShop\Module\PsEventbus\Service\ProxyService:
    class: PrestaShop\Module\PsEventbus\Service\ProxyService
    public: true
    arguments:
      - '@PrestaShop\Module\PsEventbus\Api\CollectorApiClient'
      - '@PrestaShop\Module\PsEventbus\Formatter\JsonFormatter'
      - '@PrestaShop\Module\PsEventbus\Handler\ErrorHandler\ErrorHandlerInterface'

  PrestaShop\Module\PsEventbus\Service\ApiAuthorizationService:
    class: PrestaShop\Module\PsEventbus\Service\ApiAuthorizationService
    public: true
    arguments:
      - '@PrestaShop\Module\PsEventbus\Repository\EventbusSyncRepository'
      - '@PrestaShop\Module\PsEventbus\Api\SyncApiClient'

  PrestaShop\Module\PsEventbus\Service\DeletedObjectsService:
    class: PrestaShop\Module\PsEventbus\Service\DeletedObjectsService
    public: true
    arguments:
      - "@ps_eventbus.context"
      - '@PrestaShop\Module\PsEventbus\Repository\DeletedObjectsRepository'
      - '@PrestaShop\Module\PsEventbus\Service\ProxyService'

  PrestaShop\Module\PsEventbus\Service\SynchronizationService:
    class: PrestaShop\Module\PsEventbus\Service\SynchronizationService
    public: true
    arguments:
      - '@ps_eventbus'
      - '@PrestaShop\Module\PsEventbus\Repository\EventbusSyncRepository'
      - '@PrestaShop\Module\PsEventbus\Repository\IncrementalSyncRepository'
      - '@PrestaShop\Module\PsEventbus\Repository\LiveSyncRepository'
      - '@PrestaShop\Module\PsEventbus\Repository\DeletedObjectsRepository'
      - '@PrestaShop\Module\PsEventbus\Repository\LanguageRepository'
      - '@PrestaShop\Module\PsEventbus\Decorator\PayloadDecorator'

  PrestaShop\Module\PsEventbus\Service\SpecificPriceService:
    class: PrestaShop\Module\PsEventbus\Service\SpecificPriceService
    arguments:
      - '@PrestaShop\Module\PsEventbus\Repository\SpecificPriceRepository'
    public: true

  PrestaShop\Module\PsEventbus\Service\PresenterService:
    class: PrestaShop\Module\PsEventbus\Service\PresenterService
    public: true
