REDROOM
PHP 8.2.31
Path:
Logout
Edit File
Size: 1.45 KB
Close
//opt/cpanel/ea-wappspector/vendor/rector/rector/src/Caching/CacheFactory.php
Text
Base64
<?php declare (strict_types=1); namespace Rector\Caching; use Rector\Caching\ValueObject\Storage\FileCacheStorage; use Rector\Caching\ValueObject\Storage\MemoryCacheStorage; use Rector\Configuration\Option; use Rector\Configuration\Parameter\SimpleParameterProvider; use RectorPrefix202411\Symfony\Component\Filesystem\Filesystem; final class CacheFactory { /** * @readonly * @var \Symfony\Component\Filesystem\Filesystem */ private $fileSystem; public function __construct(Filesystem $fileSystem) { $this->fileSystem = $fileSystem; } /** * @api config factory */ public function create() : \Rector\Caching\Cache { $cacheDirectory = SimpleParameterProvider::provideStringParameter(Option::CACHE_DIR); $cacheClass = FileCacheStorage::class; if (SimpleParameterProvider::hasParameter(Option::CACHE_CLASS)) { $cacheClass = SimpleParameterProvider::provideStringParameter(Option::CACHE_CLASS); } if ($cacheClass === FileCacheStorage::class) { // ensure cache directory exists if (!$this->fileSystem->exists($cacheDirectory)) { $this->fileSystem->mkdir($cacheDirectory); } $fileCacheStorage = new FileCacheStorage($cacheDirectory, $this->fileSystem); return new \Rector\Caching\Cache($fileCacheStorage); } return new \Rector\Caching\Cache(new MemoryCacheStorage()); } }
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 5 × Files: 3
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
Config
DIR
-
drwxr-xr-x
2024-11-08 13:59:10
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Contract
DIR
-
drwxr-xr-x
2024-11-08 13:59:10
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Detector
DIR
-
drwxr-xr-x
2024-11-08 13:59:10
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Enum
DIR
-
drwxr-xr-x
2024-11-08 13:59:10
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
ValueObject
DIR
-
drwxr-xr-x
2024-11-08 13:59:10
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Cache.php
1.06 KB
lrw-r--r--
2024-11-08 13:59:10
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
CacheFactory.php
1.45 KB
lrw-r--r--
2024-11-08 13:59:10
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
UnchangedFilesFilter.php
966 B
lrw-r--r--
2024-11-08 13:59:10
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).