Neos\Flow\I18n\Service::findBestMatchingLocale PHP Method

findBestMatchingLocale() public method

Returns Locale object which is the most similar to the "template" Locale object given as parameter, from the collection of locales available in the current Flow installation.
public findBestMatchingLocale ( Locale $locale ) : mixed
$locale Locale The "template" Locale to be matched
return mixed Existing Locale instance on success, NULL on failure
    public function findBestMatchingLocale(Locale $locale)
    {
        return $this->localeCollection->findBestMatchingLocale($locale);
    }