Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F7410509
CloningVisitor.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
502 B
Referenced Files
None
Subscribers
None
CloningVisitor.php
View Options
<?php
declare
(
strict_types
=
1
);
namespace
PhpParser\NodeVisitor
;
use
PhpParser\Node
;
use
PhpParser\NodeVisitorAbstract
;
/**
* Visitor cloning all nodes and linking to the original nodes using an attribute.
*
* This visitor is required to perform format-preserving pretty prints.
*/
class
CloningVisitor
extends
NodeVisitorAbstract
{
public
function
enterNode
(
Node
$origNode
)
{
$node
=
clone
$origNode
;
$node
->
setAttribute
(
'origNode'
,
$origNode
);
return
$node
;
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Sat, Nov 21, 23:00 (1 d, 15 h)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
88/34/af3460eda9bf84936cfab7abb976
Default Alt Text
CloningVisitor.php (502 B)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment