DeprecationCollector
in package
Tags
Table of Contents
- $twig : mixed
- __construct() : mixed
- collect() : array<string|int, mixed>
- Returns deprecations for passed templates.
- collectDir() : array<string|int, mixed>
- Returns deprecations for templates contained in a directory.
Properties
$twig
private
mixed
$twig
Methods
__construct()
public
__construct(Environment $twig) : mixed
Parameters
- $twig : Environment
Return values
mixed —collect()
Returns deprecations for passed templates.
public
collect(Traversable $iterator) : array<string|int, mixed>
Parameters
- $iterator : Traversable
-
An iterator of templates (where keys are template names and values the contents of the template)
Return values
array<string|int, mixed> —An array of deprecations
collectDir()
Returns deprecations for templates contained in a directory.
public
collectDir(string $dir[, string $ext = '.twig' ]) : array<string|int, mixed>
Parameters
- $dir : string
-
A directory where templates are stored
- $ext : string = '.twig'
-
Limit the loaded templates by extension
Return values
array<string|int, mixed> —An array of deprecations