REDROOM
PHP 8.2.31
Path:
Logout
Edit File
Size: 1.21 KB
Close
//opt/cpanel/ea-wappspector/vendor/rector/rector/src/PhpDocParser/PhpDocParser/PhpDocNodeVisitor/ParentConnectingPhpDocNodeVisitor.php
Text
Base64
<?php declare (strict_types=1); namespace Rector\PhpDocParser\PhpDocParser\PhpDocNodeVisitor; use PHPStan\PhpDocParser\Ast\Node; use Rector\PhpDocParser\PhpDocParser\ValueObject\PhpDocAttributeKey; /** * @api * * Mimics https://github.com/nikic/PHP-Parser/blob/master/lib/PhpParser/NodeVisitor/ParentConnectingVisitor.php * * @see \Rector\Tests\PhpDocParser\PhpDocParser\PhpDocNodeVisitor\ParentConnectingPhpDocNodeVisitorTest */ final class ParentConnectingPhpDocNodeVisitor extends \Rector\PhpDocParser\PhpDocParser\PhpDocNodeVisitor\AbstractPhpDocNodeVisitor { /** * @var Node[] */ private $stack = []; public function beforeTraverse(Node $node) : void { $this->stack = [$node]; } public function enterNode(Node $node) : Node { if ($this->stack !== []) { $parentNode = $this->stack[\count($this->stack) - 1]; $node->setAttribute(PhpDocAttributeKey::PARENT, $parentNode); } $this->stack[] = $node; return $node; } /** * @return null|int|\PhpParser\Node|Node[] Replacement node (or special return */ public function leaveNode(Node $node) { \array_pop($this->stack); return null; } }
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 0 × Files: 4
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
AbstractPhpDocNodeVisitor.php
849 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
CallablePhpDocNodeVisitor.php
921 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
CloningPhpDocNodeVisitor.php
771 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
ParentConnectingPhpDocNodeVisitor.php
1.21 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).