re-apply api changes for TimezoneDataGenerator

This commit is contained in:
Roland Franssen 2019-05-07 10:41:47 +02:00
parent c443e78dde
commit 504db27860

View File

@ -11,8 +11,8 @@
namespace Symfony\Component\Intl\Data\Generator; namespace Symfony\Component\Intl\Data\Generator;
use Symfony\Component\Intl\Data\Bundle\Compiler\GenrbCompiler; use Symfony\Component\Intl\Data\Bundle\Compiler\BundleCompilerInterface;
use Symfony\Component\Intl\Data\Bundle\Reader\BundleReaderInterface; use Symfony\Component\Intl\Data\Bundle\Reader\BundleEntryReaderInterface;
use Symfony\Component\Intl\Data\Provider\RegionDataProvider; use Symfony\Component\Intl\Data\Provider\RegionDataProvider;
use Symfony\Component\Intl\Data\Util\ArrayAccessibleResourceBundle; use Symfony\Component\Intl\Data\Util\ArrayAccessibleResourceBundle;
use Symfony\Component\Intl\Data\Util\LocaleScanner; use Symfony\Component\Intl\Data\Util\LocaleScanner;
@ -36,7 +36,7 @@ class TimezoneDataGenerator extends AbstractDataGenerator
private $zoneIds = []; private $zoneIds = [];
private $regionDataProvider; private $regionDataProvider;
public function __construct(GenrbCompiler $compiler, string $dirName, RegionDataProvider $regionDataProvider) public function __construct(BundleCompilerInterface $compiler, string $dirName, RegionDataProvider $regionDataProvider)
{ {
parent::__construct($compiler, $dirName); parent::__construct($compiler, $dirName);
@ -54,7 +54,7 @@ class TimezoneDataGenerator extends AbstractDataGenerator
/** /**
* {@inheritdoc} * {@inheritdoc}
*/ */
protected function compileTemporaryBundles(GenrbCompiler $compiler, $sourceDir, $tempDir) protected function compileTemporaryBundles(BundleCompilerInterface $compiler, $sourceDir, $tempDir)
{ {
$compiler->compile($sourceDir.'/zone', $tempDir); $compiler->compile($sourceDir.'/zone', $tempDir);
$compiler->compile($sourceDir.'/misc/timezoneTypes.txt', $tempDir); $compiler->compile($sourceDir.'/misc/timezoneTypes.txt', $tempDir);
@ -73,7 +73,7 @@ class TimezoneDataGenerator extends AbstractDataGenerator
/** /**
* {@inheritdoc} * {@inheritdoc}
*/ */
protected function generateDataForLocale(BundleReaderInterface $reader, $tempDir, $displayLocale) protected function generateDataForLocale(BundleEntryReaderInterface $reader, $tempDir, $displayLocale)
{ {
$localeBundle = $reader->read($tempDir, $displayLocale); $localeBundle = $reader->read($tempDir, $displayLocale);
@ -114,14 +114,14 @@ class TimezoneDataGenerator extends AbstractDataGenerator
/** /**
* {@inheritdoc} * {@inheritdoc}
*/ */
protected function generateDataForRoot(BundleReaderInterface $reader, $tempDir) protected function generateDataForRoot(BundleEntryReaderInterface $reader, $tempDir)
{ {
} }
/** /**
* {@inheritdoc} * {@inheritdoc}
*/ */
protected function generateDataForMeta(BundleReaderInterface $reader, $tempDir) protected function generateDataForMeta(BundleEntryReaderInterface $reader, $tempDir)
{ {
$rootBundle = $reader->read($tempDir, 'root'); $rootBundle = $reader->read($tempDir, 'root');