프로퍼티 | 타입 | 설명 | |
---|---|---|---|
$app | Illuminate\Container\Container | The IoC Container | |
$domain | string | The translation domain | |
$encoding | string | The localization encoding |
메소드 | 설명 | |
---|---|---|
__construct ( Illuminate\Container\Container $app ) | Build the language class | |
active ( string $locale ) : boolean | Whether a given language is the current one | |
defaultLocale ( ) : string | Get the default locale | |
fallbackLocale ( ) : string | Get the fallback locale | |
get ( string $key, array $replace = [], string $locale = null ) : string | Get the translation for the given key, or fallback to fallback locale | |
getAvailable ( ) : array | Get all available languages | |
getDomain ( ) : string | Get the translation domain | |
getEncoding ( boolean $slug = false ) : string | Get the encoding | |
getInternalLocale ( ) : string | Get the internal locale | |
getLocaleFolder ( string $locale ) : string | Get the folder where a locale's translations reside | |
getShortInternalLocale ( ) : string | Get the short version of the internal locale | |
getTranslationsFolder ( string $subfolder = null ) : string | Get the folder where the translations reside | |
sanitize ( string $locale = null ) : string | Sanitize a locale | |
setInternalLocale ( string | boolean $locale = false ) : string | Sets the locale according to the current language | |
setLocale ( string $locale ) : string | Change the current language | |
shortToLongLocale ( string $locale ) : string | Translate a short locale to long (en => en_US) | |
valid ( string $locale ) : boolean | Check whether a language is valid or not |
public __construct ( Illuminate\Container\Container $app ) | ||
$app | Illuminate\Container\Container |
public getAvailable ( ) : array | ||
리턴 | array | An array of languages |
public getEncoding ( boolean $slug = false ) : string | ||
$slug | boolean | |
리턴 | string |
public getLocaleFolder ( string $locale ) : string | ||
$locale | string | |
리턴 | string |
public getShortInternalLocale ( ) : string | ||
리턴 | string |
public getTranslationsFolder ( string $subfolder = null ) : string | ||
$subfolder | string | |
리턴 | string |
public shortToLongLocale ( string $locale ) : string | ||
$locale | string | |
리턴 | string |
protected Container,Illuminate\Container $app | ||
리턴 | Illuminate\Container\Container |