12 @trigger_error(
'The Twig_Function class is deprecated since version 1.12 and will be removed in 2.0. Use Twig_SimpleFunction instead.', E_USER_DEPRECATED);
30 $this->options = array_merge(
array(
31 'needs_environment' =>
false,
32 'needs_context' =>
false,
49 return $this->options[
'needs_environment'];
54 return $this->options[
'needs_context'];
59 if (isset($this->options[
'is_safe'])) {
60 return $this->options[
'is_safe'];
63 if (isset($this->options[
'is_safe_callback'])) {
64 return call_user_func($this->options[
'is_safe_callback'], $functionArgs);
72 return $this->options[
'callable'];
Represents a template function.
Represents a node in the AST.
__construct(array $options=array())
getSafe(Twig_Node $functionArgs)
Represents a template function.
Create styles array
The data for the language used.
Represents a callable template function.