public renderNode ( TYPO3\TYPO3CR\Domain\Model\NodeInterface $node, TYPO3\Flow\Mvc\Controller\ControllerContext $controllerContext ) | ||
$node | TYPO3\TYPO3CR\Domain\Model\NodeInterface | |
$controllerContext | TYPO3\Flow\Mvc\Controller\ControllerContext |
/** * Serialize node and all child nodes * * @param NodeInterface $node * @param array $list * @return array */ public function serializeNodeRecursively(NodeInterface $node, ControllerContext $controllerContext) { $result = [$node->getContextPath() => $this->nodeInfoHelper->renderNode($node, $controllerContext)]; foreach ($node->getChildNodes() as $childNode) { $result = array_merge($result, $this->serializeNodeRecursively($childNode, $controllerContext)); } return $result; }