src/CFDIReader/CFDIReader.php
private function appendChild(SimpleXMLElement $source, SimpleXMLElement $parent, array $nss): SimpleXMLElement
    {
        $new = $parent->addChild($this->normalizeName($source->getName()), (string) $source);
        $this->populateNode($source, $new, $nss);
        return $new;
    }
private function appendChild(SimpleXMLElement $source, SimpleXMLElement $parent, array $nss): SimpleXMLElement
    {
        $new = $parent->addChild($this->normalizeName($source->getName()), (string) $source);
        $this->populateNode($source, $new, $nss);
        return $new;
    }
Utility function to create a child

@param SimpleXMLElement $source
@param SimpleXMLElement $parent
@param array $nss
@return SimpleXMLElement