src/XML.php
public function dump($input, array $config = array())
    {
        $config = array_replace_recursive(array(
            'encoding' => 'UTF-8',
            'options'  => LIBXML_PARSEHUGE,
        ), $config);

        $this->prepare($input, $config);

        $paths = array();

        while ($this->nextElement()) {
            if (! $this->reader->isEmptyElement && $this->reader->nodeType === XMLReader::ELEMENT) {
                $paths[] = $this->current;
            }
        }

        return array_count_values($paths);
    }
public function dump($input, array $config = array())
    {
        $config = array_replace_recursive(array(
            'encoding' => 'UTF-8',
            'options'  => LIBXML_PARSEHUGE,
        ), $config);

        $this->prepare($input, $config);

        $paths = array();

        while ($this->nextElement()) {
            if (! $this->reader->isEmptyElement && $this->reader->nodeType === XMLReader::ELEMENT) {
                $paths[] = $this->current;
            }
        }

        return array_count_values($paths);
    }
public function dump ( $ input , array $ config = array ( ) ) { $ config = array_replace_recursive ( array ( 'encoding' => 'UTF-8' , 'options' => LIBXML_PARSEHUGE , ) , $ config ) ; $ this -> prepare ( $ input , $ config ) ; $ paths = array ( ) ; while ( $ this -> nextElement ( ) ) { if ( ! $ this -> reader -> isEmptyElement && $ this -> reader -> nodeType === XMLReader :: ELEMENT ) { $ paths [ ] = $ this -> current ; } } return array_count_values ( $ paths ) ; }
Dump XPaths and all their occurrences

@param   mixed  $input  Input data
@param   array  $config Configuration settings (optional)
@return  array
Dump XPaths and all their occurrences