public static function createSchedule(ContainerInterface $container): Schedule
    {
        $options = self::resolveOptions($container->get('config'));

        $scheduler = new Schedule($options['path'], $options['console']);

        if ($container->has(CacheItemPoolInterface::class)) {
            $scheduler->setCacheItemPool($container->get(CacheItemPoolInterface::class));
        }

        $scheduler->setContainer($container);

        return $scheduler;
    }
public static function createSchedule(ContainerInterface $container): Schedule
    {
        $options = self::resolveOptions($container->get('config'));

        $scheduler = new Schedule($options['path'], $options['console']);

        if ($container->has(CacheItemPoolInterface::class)) {
            $scheduler->setCacheItemPool($container->get(CacheItemPoolInterface::class));
        }

        $scheduler->setContainer($container);

        return $scheduler;
    }
public static function createSchedule ( ContainerInterface $ container ) : Schedule { $ options = self :: resolveOptions ( $ container -> get ( 'config' ) ) ; $ scheduler = new Schedule ( $ options [ 'path' ] , $ options [ 'console' ] ) ; if ( $ container -> has ( CacheItemPoolInterface :: class ) ) { $ scheduler -> setCacheItemPool ( $ container -> get ( CacheItemPoolInterface :: class ) ) ; } $ scheduler -> setContainer ( $ container ) ; return $ scheduler ; }
Create a new Schedule instance.

@param \Psr\Container\ContainerInterface $container

@return \Viserio\Component\Cron\Schedule
Create a new Schedule instance .