‪TYPO3CMS  11.5
TYPO3\CMS\Core\Localization\LanguageServiceFactory Class Reference

Public Member Functions

 __construct (Locales $locales, LocalizationFactory $localizationFactory, FrontendInterface $runtimeCache)
 
LanguageService create (string $locale)
 
 createFromUserPreferences (?AbstractUserAuthentication $user)
 
 createFromSiteLanguage (SiteLanguage $language)
 

Protected Attributes

Locales $locales
 
LocalizationFactory $localizationFactory
 
FrontendInterface $runtimeCache
 

Detailed Description

Definition at line 24 of file LanguageServiceFactory.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Core\Localization\LanguageServiceFactory::__construct ( Locales  $locales,
LocalizationFactory  $localizationFactory,
FrontendInterface  $runtimeCache 
)

Member Function Documentation

◆ create()

LanguageService TYPO3\CMS\Core\Localization\LanguageServiceFactory::create ( string  $locale)

Factory method to create a language service object.

Parameters
string$locale‪the locale (= the TYPO3-internal locale given)
Returns
LanguageService

Definition at line 46 of file LanguageServiceFactory.php.

Referenced by TYPO3\CMS\Redirects\Command\CleanupRedirectsCommand\__construct(), TYPO3\CMS\Core\Localization\LanguageServiceFactory\createFromSiteLanguage(), and TYPO3\CMS\Core\Localization\LanguageServiceFactory\createFromUserPreferences().

◆ createFromSiteLanguage()

TYPO3\CMS\Core\Localization\LanguageServiceFactory::createFromSiteLanguage ( SiteLanguage  $language)

◆ createFromUserPreferences()

TYPO3\CMS\Core\Localization\LanguageServiceFactory::createFromUserPreferences ( ?AbstractUserAuthentication  $user)

Member Data Documentation

◆ $locales

Locales TYPO3\CMS\Core\Localization\LanguageServiceFactory::$locales
protected

◆ $localizationFactory

LocalizationFactory TYPO3\CMS\Core\Localization\LanguageServiceFactory::$localizationFactory
protected

◆ $runtimeCache

FrontendInterface TYPO3\CMS\Core\Localization\LanguageServiceFactory::$runtimeCache
protected