public function decorate($contents, array $options = array())
    {
        return $this->getTwigEnvironment()->render(
            $this->getTemplateFilename(),
            array_merge(array('contents' => $contents), $options)
        );
    }
public function decorate($contents, array $options = array())
    {
        return $this->getTwigEnvironment()->render(
            $this->getTemplateFilename(),
            array_merge(array('contents' => $contents), $options)
        );
    }
public function decorate ( $ contents , array $ options = array ( ) ) { return $ this -> getTwigEnvironment ( ) -> render ( $ this -> getTemplateFilename ( ) , array_merge ( array ( 'contents' => $ contents ) , $ options ) ) ; }
Applies the relevant template upon the given content.

This method takes the combines the template with the given contents and generates a final piece of text
from that.

The user may add additional options that are set as parameters in the template.

@param string   $contents
@param string[] $options

@see getTemplateFileName() how the filename is assembled

@return string
Applies the relevant template upon the given content .