PHP Class Jarves\Translation\Utils

Datei anzeigen Open project: jarves/jarves

Public Properties

Property Type Description
$extractTranslations

Protected Properties

Property Type Description
$jarves Jarves\Jarves

Public Methods

Method Description
__construct ( Jarves $jarves, Cacher $cacher ) Utils constructor.
evalString ( $p )
extractAdmin ( $admin )
extractFile ( $file ) *
extractFrameworkFields ( $fields )
extractLanguage ( $bundleName )
extractTranslations ( $content )
getPluralForm ( $lang, $onlyAlgorithm = false )
parsePo ( $file )
readDirectory ( string $path ) : array | null
saveLanguage ( string $bundle, string $lang, array $translation ) : boolean
toPoString ( $string )

Protected Methods

Method Description
getJarves ( ) : Jarves

Method Details

__construct() public method

Utils constructor.
public __construct ( Jarves $jarves, Cacher $cacher )
$jarves Jarves\Jarves
$cacher Jarves\Cache\Cacher

evalString() public static method

public static evalString ( $p )

extractAdmin() public static method

public static extractAdmin ( $admin )

extractFile() public method

extracts the calls of the translation methods
public extractFile ( $file )

extractFrameworkFields() public static method

public static extractFrameworkFields ( $fields )

extractLanguage() public method

public extractLanguage ( $bundleName )

extractTranslations() public method

public extractTranslations ( $content )

getJarves() protected method

protected getJarves ( ) : Jarves
return Jarves\Jarves

getPluralForm() public method

public getPluralForm ( $lang, $onlyAlgorithm = false )

parsePo() public method

public parsePo ( $file )

readDirectory() public method

public readDirectory ( string $path ) : array | null
$path string
return array | null

saveLanguage() public method

public saveLanguage ( string $bundle, string $lang, array $translation ) : boolean
$bundle string
$lang string
$translation array
return boolean

toPoString() public static method

public static toPoString ( $string )

Property Details

$extractTranslations public_oe static_oe property

public static $extractTranslations

$jarves protected_oe property

protected Jarves,Jarves $jarves
return Jarves\Jarves