PHP Class Xinax\LaravelGettext\Translators\BaseTranslator

Afficher le fichier Open project: xinax/laravel-gettext Class Usage Examples

Protected Properties

Свойство Type Description
$adapter Framework adapter
$configuration Config container
$fileSystem Xinax\LaravelGettext\FileSystem File system helper

Méthodes publiques

Méthode Description
__toString ( ) : mixed Return the current locale
getDomain ( ) : String Returns the current domain
getEncoding ( ) : mixed Gets the Current encoding.
getLocale ( ) : String Returns the current locale string identifier
isLocaleSupported ( $locale ) : boolean Returns a boolean that indicates if $locale is supported by configuration
setDomain ( String $domain ) : self Sets the current domain and updates gettext domain application
setEncoding ( mixed $encoding ) : self Sets the Current encoding.
setLocale ( $locale ) : BaseTranslator Sets and stores on session the current locale code
supportedLocales ( ) : array Returns supported locales

Méthodes protégées

Méthode Description
sessionGet ( $key, null $default = null ) : mixed Return a value from session with an optional default
sessionSet ( $key, $value ) : mixed Sets a value in session session

Method Details

__toString() public méthode

Return the current locale
public __toString ( ) : mixed
Résultat mixed

getDomain() public méthode

Returns the current domain
public getDomain ( ) : String
Résultat String

getEncoding() public méthode

Gets the Current encoding.
public getEncoding ( ) : mixed
Résultat mixed

getLocale() public méthode

Returns the current locale string identifier
public getLocale ( ) : String
Résultat String

isLocaleSupported() public méthode

Returns a boolean that indicates if $locale is supported by configuration
public isLocaleSupported ( $locale ) : boolean
Résultat boolean

sessionGet() protected méthode

Return a value from session with an optional default
protected sessionGet ( $key, null $default = null ) : mixed
$key
$default null
Résultat mixed

sessionSet() protected méthode

Sets a value in session session
protected sessionSet ( $key, $value ) : mixed
$key
$value
Résultat mixed

setDomain() public méthode

Sets the current domain and updates gettext domain application
public setDomain ( String $domain ) : self
$domain String
Résultat self

setEncoding() public méthode

Sets the Current encoding.
public setEncoding ( mixed $encoding ) : self
$encoding mixed the encoding
Résultat self

setLocale() public méthode

Sets and stores on session the current locale code
public setLocale ( $locale ) : BaseTranslator
Résultat BaseTranslator

supportedLocales() public méthode

Returns supported locales
public supportedLocales ( ) : array
Résultat array

Property Details

$adapter protected_oe property

Framework adapter
protected $adapter

$configuration protected_oe property

Config container
protected $configuration

$fileSystem protected_oe property

File system helper
protected FileSystem,Xinax\LaravelGettext $fileSystem
Résultat Xinax\LaravelGettext\FileSystem