TwigFilter
in package
Represents a template filter.
Tags
Table of Contents
- $arguments : mixed
- $callable : mixed
- $name : mixed
- $options : mixed
- __construct() : mixed
- Creates a template filter.
- getAlternative() : mixed
- getArguments() : mixed
- getCallable() : callable|null
- Returns the callable to execute for this filter.
- getDeprecatedVersion() : mixed
- getName() : mixed
- getNodeClass() : mixed
- getPreEscape() : mixed
- getPreservesSafety() : mixed
- getSafe() : mixed
- isDeprecated() : mixed
- isVariadic() : mixed
- needsContext() : mixed
- needsEnvironment() : mixed
- setArguments() : mixed
Properties
$arguments
private
mixed
$arguments
= []
$callable
private
mixed
$callable
$name
private
mixed
$name
$options
private
mixed
$options
Methods
__construct()
Creates a template filter.
public
__construct(string $name[, callable|null $callable = null ][, array<string|int, mixed> $options = [] ]) : mixed
Parameters
- $name : string
-
Name of this filter
- $callable : callable|null = null
-
A callable implementing the filter. If null, you need to overwrite the "node_class" option to customize compilation.
- $options : array<string|int, mixed> = []
-
Options array
Return values
mixed —getAlternative()
public
getAlternative() : mixed
Return values
mixed —getArguments()
public
getArguments() : mixed
Return values
mixed —getCallable()
Returns the callable to execute for this filter.
public
getCallable() : callable|null
Return values
callable|null —getDeprecatedVersion()
public
getDeprecatedVersion() : mixed
Return values
mixed —getName()
public
getName() : mixed
Return values
mixed —getNodeClass()
public
getNodeClass() : mixed
Return values
mixed —getPreEscape()
public
getPreEscape() : mixed
Return values
mixed —getPreservesSafety()
public
getPreservesSafety() : mixed
Return values
mixed —getSafe()
public
getSafe(Node $filterArgs) : mixed
Parameters
- $filterArgs : Node
Return values
mixed —isDeprecated()
public
isDeprecated() : mixed
Return values
mixed —isVariadic()
public
isVariadic() : mixed
Return values
mixed —needsContext()
public
needsContext() : mixed
Return values
mixed —needsEnvironment()
public
needsEnvironment() : mixed
Return values
mixed —setArguments()
public
setArguments(mixed $arguments) : mixed
Parameters
- $arguments : mixed