src/Kunstmaan/TranslatorBundle/Service/Command/Exporter/ExportCommandHandler.php
public function getTranslations(ExportCommand $exportCommand)
    {
        $locales = $this->determineLocalesToImport($exportCommand);
        $domains = $this->determineDomainsToImport($exportCommand);

        $translations = [];
        /** @var Translation $translation */
        foreach ($this->translationRepository->getTranslationsByLocalesAndDomains($locales, $domains) as $translation) {
            // Sort by translation key.
            $translations[$translation->getKeyword()][$translation->getLocale()] = $translation;
        }

        return $translations;
    }
public function getTranslations(ExportCommand $exportCommand)
    {
        $locales = $this->determineLocalesToImport($exportCommand);
        $domains = $this->determineDomainsToImport($exportCommand);

        $translations = [];
        /** @var Translation $translation */
        foreach ($this->translationRepository->getTranslationsByLocalesAndDomains($locales, $domains) as $translation) {
            // Sort by translation key.
            $translations[$translation->getKeyword()][$translation->getLocale()] = $translation;
        }

        return $translations;
    }
public function getTranslations ( ExportCommand $ exportCommand ) { $ locales = $ this -> determineLocalesToImport ( $ exportCommand ) ; $ domains = $ this -> determineDomainsToImport ( $ exportCommand ) ; $ translations = [ ] ; /** @var Translation $translation */ foreach ( $ this -> translationRepository -> getTranslationsByLocalesAndDomains ( $ locales , $ domains ) as $ translation ) { // Sort by translation key. $ translations [ $ translation -> getKeyword ( ) ] [ $ translation -> getLocale ( ) ] = $ translation ; } return $ translations ; }
Convert an exportCommand into an array of translations

@param ExportCommand $exportCommand

@return array an array of translations
Convert an exportCommand into an array of translations