public function visitElement(\DOMNode $domElement) { $directories = $this->locator->locateDirectories($domElement->nodeValue); $domDocument = $domElement->ownerDocument; $parentNode = $domElement->parentNode; $domElement->parentNode->removeChild($domElement); foreach ($directories as $directory) { $parentNode->appendChild($domDocument->createElement($domElement->tagName, $directory)); } }
public function visitElement(\DOMNode $domElement) { $domElement->nodeValue = $this->locator->locate($domElement->nodeValue); }