PHP Class Symfony\Bridge\Twig\Translation\TwigExtractor

Author: Michel Salib ([email protected])
Inheritance: implements Symfony\Component\Translation\Extractor\ExtractorInterface
显示文件 Open project: symfony/symfony Class Usage Examples

Public Methods

Method Description
__construct ( Twig_Environment $twig )
extract ( $resource, Symfony\Component\Translation\MessageCatalogue $catalogue )
setPrefix ( $prefix )

Protected Methods

Method Description
canBeExtracted ( string $file ) : boolean
extractFromDirectory ( string | array $directory ) : array
extractTemplate ( $template, Symfony\Component\Translation\MessageCatalogue $catalogue )

Method Details

__construct() public method

public __construct ( Twig_Environment $twig )
$twig Twig_Environment

canBeExtracted() protected method

protected canBeExtracted ( string $file ) : boolean
$file string
return boolean

extract() public method

public extract ( $resource, Symfony\Component\Translation\MessageCatalogue $catalogue )
$catalogue Symfony\Component\Translation\MessageCatalogue

extractFromDirectory() protected method

protected extractFromDirectory ( string | array $directory ) : array
$directory string | array
return array

extractTemplate() protected method

protected extractTemplate ( $template, Symfony\Component\Translation\MessageCatalogue $catalogue )
$catalogue Symfony\Component\Translation\MessageCatalogue

setPrefix() public method

public setPrefix ( $prefix )