Upgrade code from 146 to new standards

This commit is contained in:
2023-10-16 18:04:40 +02:00
parent 8523f14214
commit 6b8d6b76ba
38 changed files with 56 additions and 62 deletions

View File

@@ -101,7 +101,7 @@ class ExportManager
*
* @return FilterInterface[] a \Generator that contains filters. The key is the filter's alias
*/
public function &getFiltersApplyingOn(ExportInterface|DirectExportInterface $export, ?array $centers = null): iterable
public function &getFiltersApplyingOn(DirectExportInterface|ExportInterface $export, ?array $centers = null): iterable
{
if ($export instanceof DirectExportInterface) {
return;
@@ -124,7 +124,7 @@ class ExportManager
*
* @return null|iterable<string, AggregatorInterface> a \Generator that contains aggretagors. The key is the filter's alias
*/
public function &getAggregatorsApplyingOn(ExportInterface|DirectExportInterface $export, ?array $centers = null): ?iterable
public function &getAggregatorsApplyingOn(DirectExportInterface|ExportInterface $export, ?array $centers = null): ?iterable
{
if ($export instanceof ListInterface || $export instanceof DirectExportInterface) {
return;
@@ -307,7 +307,7 @@ class ExportManager
*
* @throws RuntimeException
*/
public function getExport($alias): ExportInterface|DirectExportInterface
public function getExport($alias): DirectExportInterface|ExportInterface
{
if (!array_key_exists($alias, $this->exports)) {
throw new RuntimeException("The export with alias {$alias} is not known.");
@@ -453,7 +453,7 @@ class ExportManager
*
*/
public function isGrantedForElement(
ExportInterface|DirectExportInterface|ModifierInterface $element,
DirectExportInterface|ExportInterface|ModifierInterface $element,
\Chill\MainBundle\Export\DirectExportInterface|\Chill\MainBundle\Export\ExportInterface $export = null,
?array $centers = null
): bool {