class TemplateCacheCacheWarmer implements CacheWarmerInterface
Generates the Twig cache for all templates.
This warmer must be registered after TemplatePathsCacheWarmer,
as the Twig loader will need the cache generated by it.
Methods
|
__construct(ContainerInterface $container, TemplateFinderInterface $finder)
Constructor. |
||
|
warmUp(string $cacheDir)
Warms up the cache. |
||
| Boolean |
isOptional()
Checks whether this warmer is optional or not. |
Details
at line 37
public
__construct(ContainerInterface $container, TemplateFinderInterface $finder)
Constructor.
at line 52
public
warmUp(string $cacheDir)
Warms up the cache.
at line 74
public Boolean
isOptional()
Checks whether this warmer is optional or not.
Optional warmers can be ignored on certain conditions.
A warmer should return true if the cache can be
generated incrementally and on-demand.