Function.php 677B

1234567891011121314151617181920212223242526272829303132333435
  1. <?php
  2. /*
  3. * This file is part of Twig.
  4. *
  5. * (c) 2009 Fabien Potencier
  6. * (c) 2010 Arnaud Le Blanc
  7. *
  8. * For the full copyright and license information, please view the LICENSE
  9. * file that was distributed with this source code.
  10. */
  11. /**
  12. * Represents a function template function.
  13. *
  14. * @package twig
  15. * @author Arnaud Le Blanc <arnaud.lb@gmail.com>
  16. */
  17. class Twig_Function_Function extends Twig_Function
  18. {
  19. protected $function;
  20. public function __construct($function, array $options = array())
  21. {
  22. parent::__construct($options);
  23. $this->function = $function;
  24. }
  25. public function compile()
  26. {
  27. return $this->function;
  28. }
  29. }