Ubiquity 2.5.2
php rapid development framework
Loading...
Searching...
No Matches
Translator Class Reference

Injectable translator (to use with di) More...

Public Member Functions

 __construct ($locale="en_EN", $fallbackLocale=null, $rootDir=null)
 
 setLocale ($locale)
 
 setRootDir ($rootDir=null)
 
 getLocale ()
 
 trans ($id, array $parameters=array(), $domain=null, $locale=null)
 
 getCatalogue (&$locale=null)
 
 loadCatalogue ($locale=null)
 
 getFallbackLocale ()
 
 setFallbackLocale ($fallbackLocale)
 
 clearCache ()
 

Private Attributes

 $manager
 

Detailed Description

Injectable translator (to use with di)

Author
jcheron myadd.nosp@m.ress.nosp@m.mail@.nosp@m.gmai.nosp@m.l.com
Version
1.0.1

Definition at line 10 of file Translator.php.

Constructor & Destructor Documentation

◆ __construct()

__construct (   $locale = "en_EN",
  $fallbackLocale = null,
  $rootDir = null 
)

Definition at line 13 of file Translator.php.

Member Function Documentation

◆ clearCache()

clearCache ( )

Definition at line 56 of file Translator.php.

◆ getCatalogue()

getCatalogue ( $locale = null)

Definition at line 34 of file Translator.php.

◆ getFallbackLocale()

getFallbackLocale ( )
Returns
mixed

Definition at line 45 of file Translator.php.

◆ getLocale()

getLocale ( )

Definition at line 26 of file Translator.php.

◆ loadCatalogue()

loadCatalogue (   $locale = null)

Definition at line 38 of file Translator.php.

◆ setFallbackLocale()

setFallbackLocale (   $fallbackLocale)
Parameters
mixed$fallbackLocale

Definition at line 52 of file Translator.php.

◆ setLocale()

setLocale (   $locale)

Definition at line 18 of file Translator.php.

◆ setRootDir()

setRootDir (   $rootDir = null)

Definition at line 22 of file Translator.php.

◆ trans()

trans (   $id,
array  $parameters = array(),
  $domain = null,
  $locale = null 
)

Definition at line 30 of file Translator.php.

Field Documentation

◆ $manager

$manager
private

Definition at line 11 of file Translator.php.


The documentation for this class was generated from the following file: