REDROOM
PHP 8.2.31
Path:
Logout
Edit File
Size: 1.25 KB
Close
/opt/cpanel/ea-wappspector/vendor/rector/rector/rules/CodingStyle/Reflection/VendorLocationDetector.php
Text
Base64
<?php declare (strict_types=1); namespace Rector\CodingStyle\Reflection; use PHPStan\Reflection\FunctionReflection; use PHPStan\Reflection\MethodReflection; use Rector\FileSystem\FilePathHelper; final class VendorLocationDetector { /** * @readonly * @var \Rector\FileSystem\FilePathHelper */ private $filePathHelper; public function __construct(FilePathHelper $filePathHelper) { $this->filePathHelper = $filePathHelper; } public function detectMethodReflection(MethodReflection $methodReflection) : bool { $declaringClassReflection = $methodReflection->getDeclaringClass(); $fileName = $declaringClassReflection->getFileName(); return $this->detect($fileName); } public function detectFunctionReflection(FunctionReflection $functionReflection) : bool { $fileName = $functionReflection->getFileName(); return $this->detect($fileName); } private function detect(?string $fileName = null) : bool { // probably internal if ($fileName === null) { return \false; } $normalizedFileName = $this->filePathHelper->normalizePathAndSchema($fileName); return \strpos($normalizedFileName, '/vendor/') !== \false; } }
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 0 × Files: 1
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
VendorLocationDetector.php
1.25 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
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).