Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. NodeDumper.php

function NodeDumper::dump

Dumps a node or array.

Parameters

array|Node $node Node or array to dump:

string|null $code Code corresponding to dumped AST. This only needs to be passed if: the dumpPositions option is enabled and the dumping of node offsets is desired.

Return value

string Dumped value

File

vendor/nikic/php-parser/lib/PhpParser/NodeDumper.php, line 60

Class

NodeDumper

Namespace

PhpParser

Code

public function dump($node, ?string $code = null) : string {
    $this->code = $code;
    $this->res = '';
    $this->nl = "\n";
    $this->dumpRecursive($node, false);
    return $this->res;
}
RSS feed
Powered by Drupal