HamlPHP::getCompiler PHP Méthode

getCompiler() public méthode

Returns a compiler object.
public getCompiler ( ) : Compiler
Résultat Compiler
    public function getCompiler()
    {
        if ($this->_compiler === null) {
            $this->_compiler = new Compiler($this);
        }
        return $this->_compiler;
    }

Usage Example

Exemple #1
0
 public function __construct()
 {
     $this->evaluator = new ContentEvaluator();
     $hamlPHP = new HamlPHP(new FileStorage(dirname(__FILE__) . '/tmp/'));
     $hamlPHP->disableCache();
     $this->compiler = $hamlPHP->getCompiler();
 }