public static function createCachedFactory(ContainerInterface $container): CachedFactory
    {
        $cache = null;

        if ($container->has(CacheManagerContract::class)) {
            $cache = $container->get(CacheManagerContract::class);
        }

        return new CachedFactory(
            $container->get(FilesystemManager::class),
            $cache
        );
    }
public static function createCachedFactory(ContainerInterface $container): CachedFactory
    {
        $cache = null;

        if ($container->has(CacheManagerContract::class)) {
            $cache = $container->get(CacheManagerContract::class);
        }

        return new CachedFactory(
            $container->get(FilesystemManager::class),
            $cache
        );
    }
public static function createCachedFactory ( ContainerInterface $ container ) : CachedFactory { $ cache = null ; if ( $ container -> has ( CacheManagerContract :: class ) ) { $ cache = $ container -> get ( CacheManagerContract :: class ) ; } return new CachedFactory ( $ container -> get ( FilesystemManager :: class ) , $ cache ) ; }
Create a new CachedFactory instance.

@param \Psr\Container\ContainerInterface $container

@return \Viserio\Component\Filesystem\Cache\CachedFactory
Create a new CachedFactory instance .