Twig_Loader_Chain

Extends\Twig\Loader\ChainLoader

Loads templates from other loaders.

package

Default

Methods

__construct

__construct(array<mixed,\Twig\Loader\LoaderInterface> $loaders = array())
inherited

Arguments

$loaders

array<mixed,\Twig\Loader\LoaderInterface>

addLoader

addLoader(\Twig\Loader\LoaderInterface $loader)
inherited

Arguments

Check if we have the source code of a template, given its name.

exists(string $name): boolean
inherited

Arguments

$name

string

The name of the template to check if we can load

Response

boolean

If the template source code is handled by this loader or not

Gets the cache key to use for the cache for a given template name.

getCacheKey(string $name): string
inherited

Arguments

$name

string

The name of the template to load

Response

string

The cache key

getLoaders

getLoaders(): array<mixed,\Twig\Loader\LoaderInterface>
inherited

Response

array<mixed,\Twig\Loader\LoaderInterface>

Gets the source code of a template, given its name.

getSource(string $name): string
inherited

Arguments

$name

string

The name of the template to load

Response

string

The template source code

Returns the source context for a given template logical name.

getSourceContext(string $name): \Twig\Source
inherited

Arguments

$name

string

The template logical name

Response

\Twig\Source

Returns true if the template is still fresh.

isFresh(string $name,integer $time): boolean
inherited

Arguments

$name

string

The template name

$time

integer

Timestamp of the last modification time of the cached template

Response

boolean

true if the template is fresh, false otherwise

Properties

hasSourceCache

hasSourceCache :
inherited

Type(s)

loaders

loaders :
inherited

Type(s)