public static function createFast(ContainerInterface $container) { $service = 'jarves.cache.backend.'; if (function_exists('apc_store')) { $service .= 'apc'; } else { $service .= 'files'; } $cacheConfig = new Cache(); /** @var CacheInterface $instance */ $instance = $container->get($service); $instance->configure($cacheConfig); return $instance; }