Automattic\WooCommerce\Vendor\GraphQL\Language\AST
NodeList::cloneDeep
Returns a clone of this instance and all its children, except Location $loc.
Method of the class: NodeList{}
No Hooks.
Returns
static
Usage
$NodeList = new NodeList(); $NodeList->cloneDeep(): self;
NodeList::cloneDeep() NodeList::cloneDeep code WC 10.9.1
public function cloneDeep(): self
{
/** @var array<T> $empty */
$empty = [];
$cloned = new static($empty);
foreach ($this->getIterator() as $key => $node) {
$cloned[$key] = $node->cloneDeep();
}
return $cloned;
}