<?php

namespace Openguru\OpenCartFramework\Scheduler;

use Openguru\OpenCartFramework\Cache\CacheInterface;
use Openguru\OpenCartFramework\Config\Settings;
use Openguru\OpenCartFramework\Container\Container;
use Openguru\OpenCartFramework\Container\ServiceProvider;
use Psr\Log\LoggerInterface;

class SchedulerServiceProvider extends ServiceProvider
{
    public function register(): void
    {
        $this->container->singleton(SchedulerService::class, function (Container $container) {
            return new SchedulerService(
                $container->get(LoggerInterface::class),
                $container->get(CacheInterface::class),
                $container,
                $container->get(Settings::class)
            );
        });
    }
}
