Neos.ContentRepository/Classes/Domain/Service/ImportExport/NodeImportService.php
protected function importSubtree(\XMLReader $xmlReader)
    {
        while ($xmlReader->read()) {
            if ($xmlReader->nodeType === \XMLReader::COMMENT) {
                continue;
            }

            switch ($xmlReader->nodeType) {
                case \XMLReader::ELEMENT:
                    if (!$xmlReader->isEmptyElement) {
                        $this->parseElement($xmlReader);
                    }
                    break;
                case \XMLReader::END_ELEMENT:
                    if ((string)$xmlReader->name === 'nodes') {
                        return; // all done, reached the closing </nodes> tag
                    }
                    $this->parseEndElement($xmlReader);
                    break;
            }
        }
    }
protected function importSubtree(\XMLReader $xmlReader)
    {
        while ($xmlReader->read()) {
            if ($xmlReader->nodeType === \XMLReader::COMMENT) {
                continue;
            }

            switch ($xmlReader->nodeType) {
                case \XMLReader::ELEMENT:
                    if (!$xmlReader->isEmptyElement) {
                        $this->parseElement($xmlReader);
                    }
                    break;
                case \XMLReader::END_ELEMENT:
                    if ((string)$xmlReader->name === 'nodes') {
                        return; // all done, reached the closing </nodes> tag
                    }
                    $this->parseEndElement($xmlReader);
                    break;
            }
        }
    }
protected function importSubtree ( \ XMLReader $ xmlReader ) { while ( $ xmlReader -> read ( ) ) { if ( $ xmlReader -> nodeType === \ XMLReader :: COMMENT ) { continue ; } switch ( $ xmlReader -> nodeType ) { case \ XMLReader :: ELEMENT : if ( ! $ xmlReader -> isEmptyElement ) { $ this -> parseElement ( $ xmlReader ) ; } break ; case \ XMLReader :: END_ELEMENT : if ( ( string ) $ xmlReader -> name === 'nodes' ) { return ; // all done, reached the closing </nodes> tag } $ this -> parseEndElement ( $ xmlReader ) ; break ; } } }
Imports the sub-tree from the xml reader into the given target path.
The root node of the imported tree becomes a child of the node specified by target path.

This parser uses the depth-first reading strategy, which means it will read the input from top til bottom.

@param \XMLReader $xmlReader A prepared XML Reader with the structure to import
@return void
Imports the sub - tree from the xml reader into the given target path . The root node of the imported tree becomes a child of the node specified by target path .