protected function parseFiles(array $sourcePaths)
    {
        $parsedFiles = [];

        foreach ($sourcePaths as $sourcePath) {
            $parsedFiles[] = $this->cldrParser->getParsedData($sourcePath);
        }

        // Merge all data starting with most generic file so we get proper inheritance
        $parsedData = $parsedFiles[0];

        $parsedFilesCount = count($parsedFiles);
        for ($i = 1; $i < $parsedFilesCount; ++$i) {
            $parsedData = $this->mergeTwoParsedFiles($parsedData, $parsedFiles[$i]);
        }

        return $parsedData;
    }
protected function parseFiles(array $sourcePaths)
    {
        $parsedFiles = [];

        foreach ($sourcePaths as $sourcePath) {
            $parsedFiles[] = $this->cldrParser->getParsedData($sourcePath);
        }

        // Merge all data starting with most generic file so we get proper inheritance
        $parsedData = $parsedFiles[0];

        $parsedFilesCount = count($parsedFiles);
        for ($i = 1; $i < $parsedFilesCount; ++$i) {
            $parsedData = $this->mergeTwoParsedFiles($parsedData, $parsedFiles[$i]);
        }

        return $parsedData;
    }
protected function parseFiles ( array $ sourcePaths ) { $ parsedFiles = [ ] ; foreach ( $ sourcePaths as $ sourcePath ) { $ parsedFiles [ ] = $ this -> cldrParser -> getParsedData ( $ sourcePath ) ; } // Merge all data starting with most generic file so we get proper inheritance $ parsedData = $ parsedFiles [ 0 ] ; $ parsedFilesCount = count ( $ parsedFiles ) ; for ( $ i = 1 ; $ i < $ parsedFilesCount ; ++ $ i ) { $ parsedData = $ this -> mergeTwoParsedFiles ( $ parsedData , $ parsedFiles [ $ i ] ) ; } return $ parsedData ; }
Parses given CLDR files using CldrParser and merges parsed data.

Merging is done with inheritance in mind, as defined in CLDR specification.

@param array<string> $sourcePaths Absolute paths to CLDR files (can be one file)
@return array Parsed and merged data
Parses given CLDR files using CldrParser and merges parsed data .