From 874b8cbf002e9d8bf0ff39671e1501165016320a Mon Sep 17 00:00:00 2001 From: Michael Save Date: Mon, 9 Apr 2012 20:52:26 +1000 Subject: inc/contrib -> inc/lib --- inc/contrib/Twig/Filter.php | 58 --------------------------------------------- 1 file changed, 58 deletions(-) delete mode 100644 inc/contrib/Twig/Filter.php (limited to 'inc/contrib/Twig/Filter.php') diff --git a/inc/contrib/Twig/Filter.php b/inc/contrib/Twig/Filter.php deleted file mode 100644 index 9595a1a8..00000000 --- a/inc/contrib/Twig/Filter.php +++ /dev/null @@ -1,58 +0,0 @@ - - */ -abstract class Twig_Filter implements Twig_FilterInterface -{ - protected $options; - - public function __construct(array $options = array()) - { - $this->options = array_merge(array( - 'needs_environment' => false, - 'needs_context' => false, - 'pre_escape' => null, - ), $options); - } - - public function needsEnvironment() - { - return $this->options['needs_environment']; - } - - public function needsContext() - { - return $this->options['needs_context']; - } - - public function getSafe(Twig_Node $filterArgs) - { - if (isset($this->options['is_safe'])) { - return $this->options['is_safe']; - } - - if (isset($this->options['is_safe_callback'])) { - return call_user_func($this->options['is_safe_callback'], $filterArgs); - } - - return array(); - } - - public function getPreEscape() - { - return $this->options['pre_escape']; - } -} -- cgit v1.3