Spade
Mini Shell
| Directory:~$ /home/lmsyaran/public_html/joomla4/ |
| [Home] [System Details] [Kill Me] |
Autoloader.php000064400000002710151160705100007350 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
@trigger_error('The Twig_Autoloader class is deprecated since version
1.21 and will be removed in 2.0. Use Composer instead.',
E_USER_DEPRECATED);
/**
* Autoloads Twig classes.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.21 and will be removed in 2.0. Use Composer instead.
2.0.
*/
class Twig_Autoloader
{
/**
* Registers Twig_Autoloader as an SPL autoloader.
*
* @param bool $prepend whether to prepend the autoloader or not
*/
public static function register($prepend = false)
{
@trigger_error('Using Twig_Autoloader is deprecated since
version 1.21. Use Composer instead.', E_USER_DEPRECATED);
spl_autoload_register([__CLASS__, 'autoload'], true,
$prepend);
}
/**
* Handles autoloading of classes.
*
* @param string $class a class name
*/
public static function autoload($class)
{
if (0 !== strpos($class, 'Twig')) {
return;
}
if (is_file($file =
__DIR__.'/../'.str_replace(['_', "\0"],
['/', ''], $class).'.php')) {
require $file;
} elseif (is_file($file =
__DIR__.'/../../src/'.str_replace(['Twig\\',
'\\', "\0"], ['', '/',
''], $class).'.php')) {
require $file;
}
}
}
BaseNodeVisitor.php000064400000000300151160705100010302 0ustar00<?php
use Twig\NodeVisitor\AbstractNodeVisitor;
class_exists('Twig\NodeVisitor\AbstractNodeVisitor');
if (\false) {
class Twig_BaseNodeVisitor extends AbstractNodeVisitor
{
}
}
Cache/Filesystem.php000064400000000251151160705100010376 0ustar00<?php
use Twig\Cache\FilesystemCache;
class_exists('Twig\Cache\FilesystemCache');
if (\false) {
class Twig_Cache_Filesystem extends FilesystemCache
{
}
}
Cache/Null.php000064400000000221151160705100007161 0ustar00<?php
use Twig\Cache\NullCache;
class_exists('Twig\Cache\NullCache');
if (\false) {
class Twig_Cache_Null extends NullCache
{
}
}
CacheInterface.php000064400000000244151160705100010075 0ustar00<?php
use Twig\Cache\CacheInterface;
class_exists('Twig\Cache\CacheInterface');
if (\false) {
class Twig_CacheInterface extends CacheInterface
{
}
}
Compiler.php000064400000000200151160705100007013 0ustar00<?php
use Twig\Compiler;
class_exists('Twig\Compiler');
if (\false) {
class Twig_Compiler extends Compiler
{
}
}
CompilerInterface.php000064400000001230151160705100010640 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
/**
* Interface implemented by compiler classes.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 3.0)
*/
interface Twig_CompilerInterface
{
/**
* Compiles a node.
*
* @return $this
*/
public function compile(Twig_NodeInterface $node);
/**
* Gets the current PHP code after compilation.
*
* @return string The PHP code
*/
public function getSource();
}
ContainerRuntimeLoader.php000064400000000324151160705100011665
0ustar00<?php
use Twig\RuntimeLoader\ContainerRuntimeLoader;
class_exists('Twig\RuntimeLoader\ContainerRuntimeLoader');
if (\false) {
class Twig_ContainerRuntimeLoader extends ContainerRuntimeLoader
{
}
}
Environment.php000064400000000214151160705100007552 0ustar00<?php
use Twig\Environment;
class_exists('Twig\Environment');
if (\false) {
class Twig_Environment extends Environment
{
}
}
Error/Loader.php000064400000000231151160705100007544 0ustar00<?php
use Twig\Error\LoaderError;
class_exists('Twig\Error\LoaderError');
if (\false) {
class Twig_Error_Loader extends LoaderError
{
}
}
Error/Runtime.php000064400000000235151160705100007765 0ustar00<?php
use Twig\Error\RuntimeError;
class_exists('Twig\Error\RuntimeError');
if (\false) {
class Twig_Error_Runtime extends RuntimeError
{
}
}
Error/Syntax.php000064400000000231151160705100007624 0ustar00<?php
use Twig\Error\SyntaxError;
class_exists('Twig\Error\SyntaxError');
if (\false) {
class Twig_Error_Syntax extends SyntaxError
{
}
}
Error.php000064400000000200151160705100006332 0ustar00<?php
use Twig\Error\Error;
class_exists('Twig\Error\Error');
if (\false) {
class Twig_Error extends Error
{
}
}
ExistsLoaderInterface.php000064400000000302151160705100011473
0ustar00<?php
use Twig\Loader\ExistsLoaderInterface;
class_exists('Twig\Loader\ExistsLoaderInterface');
if (\false) {
class Twig_ExistsLoaderInterface extends ExistsLoaderInterface
{
}
}
ExpressionParser.php000064400000000240151160705100010561 0ustar00<?php
use Twig\ExpressionParser;
class_exists('Twig\ExpressionParser');
if (\false) {
class Twig_ExpressionParser extends ExpressionParser
{
}
}
Extension/Core.php000064400000000251151160705100010113 0ustar00<?php
use Twig\Extension\CoreExtension;
class_exists('Twig\Extension\CoreExtension');
if (\false) {
class Twig_Extension_Core extends CoreExtension
{
}
}
Extension/Debug.php000064400000000255151160705100010255 0ustar00<?php
use Twig\Extension\DebugExtension;
class_exists('Twig\Extension\DebugExtension');
if (\false) {
class Twig_Extension_Debug extends DebugExtension
{
}
}
Extension/Escaper.php000064400000000265151160705100010612 0ustar00<?php
use Twig\Extension\EscaperExtension;
class_exists('Twig\Extension\EscaperExtension');
if (\false) {
class Twig_Extension_Escaper extends EscaperExtension
{
}
}
Extension/GlobalsInterface.php000064400000000276151160705100012436
0ustar00<?php
use Twig\Extension\GlobalsInterface;
class_exists('Twig\Extension\GlobalsInterface');
if (\false) {
class Twig_Extension_GlobalsInterface extends GlobalsInterface
{
}
}
Extension/InitRuntimeInterface.php000064400000000316151160705100013315
0ustar00<?php
use Twig\Extension\InitRuntimeInterface;
class_exists('Twig\Extension\InitRuntimeInterface');
if (\false) {
class Twig_Extension_InitRuntimeInterface extends InitRuntimeInterface
{
}
}
Extension/Optimizer.php000064400000000275151160705100011213
0ustar00<?php
use Twig\Extension\OptimizerExtension;
class_exists('Twig\Extension\OptimizerExtension');
if (\false) {
class Twig_Extension_Optimizer extends OptimizerExtension
{
}
}
Extension/Profiler.php000064400000000271151160705100011007 0ustar00<?php
use Twig\Extension\ProfilerExtension;
class_exists('Twig\Extension\ProfilerExtension');
if (\false) {
class Twig_Extension_Profiler extends ProfilerExtension
{
}
}
Extension/Sandbox.php000064400000000265151160705100010626 0ustar00<?php
use Twig\Extension\SandboxExtension;
class_exists('Twig\Extension\SandboxExtension');
if (\false) {
class Twig_Extension_Sandbox extends SandboxExtension
{
}
}
Extension/Staging.php000064400000000265151160705100010624 0ustar00<?php
use Twig\Extension\StagingExtension;
class_exists('Twig\Extension\StagingExtension');
if (\false) {
class Twig_Extension_Staging extends StagingExtension
{
}
}
Extension/StringLoader.php000064400000000311151160705100011615
0ustar00<?php
use Twig\Extension\StringLoaderExtension;
class_exists('Twig\Extension\StringLoaderExtension');
if (\false) {
class Twig_Extension_StringLoader extends StringLoaderExtension
{
}
}
Extension.php000064400000000260151160705100007223 0ustar00<?php
use Twig\Extension\AbstractExtension;
class_exists('Twig\Extension\AbstractExtension');
if (\false) {
class Twig_Extension extends AbstractExtension
{
}
}
ExtensionInterface.php000064400000000274151160705100011051 0ustar00<?php
use Twig\Extension\ExtensionInterface;
class_exists('Twig\Extension\ExtensionInterface');
if (\false) {
class Twig_ExtensionInterface extends ExtensionInterface
{
}
}
FactoryRuntimeLoader.php000064400000000314151160705100011351
0ustar00<?php
use Twig\RuntimeLoader\FactoryRuntimeLoader;
class_exists('Twig\RuntimeLoader\FactoryRuntimeLoader');
if (\false) {
class Twig_FactoryRuntimeLoader extends FactoryRuntimeLoader
{
}
}
FileExtensionEscapingStrategy.php000064400000000324151160705100013221
0ustar00<?php
use Twig\FileExtensionEscapingStrategy;
class_exists('Twig\FileExtensionEscapingStrategy');
if (\false) {
class Twig_FileExtensionEscapingStrategy extends
FileExtensionEscapingStrategy
{
}
}
Filter/Function.php000064400000001605151160705100010265 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
@trigger_error('The Twig_Filter_Function class is deprecated since
version 1.12 and will be removed in 2.0. Use \Twig\TwigFilter
instead.', E_USER_DEPRECATED);
/**
* Represents a function template filter.
*
* Use \Twig\TwigFilter instead.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
class Twig_Filter_Function extends Twig_Filter
{
protected $function;
public function __construct($function, array $options = [])
{
$options['callable'] = $function;
parent::__construct($options);
$this->function = $function;
}
public function compile()
{
return $this->function;
}
}
Filter/Method.php000064400000002130151160705100007712 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\Extension\ExtensionInterface;
@trigger_error('The Twig_Filter_Method class is deprecated since
version 1.12 and will be removed in 2.0. Use \Twig\TwigFilter
instead.', E_USER_DEPRECATED);
/**
* Represents a method template filter.
*
* Use \Twig\TwigFilter instead.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
class Twig_Filter_Method extends Twig_Filter
{
protected $extension;
protected $method;
public function __construct(ExtensionInterface $extension, $method,
array $options = [])
{
$options['callable'] = [$extension, $method];
parent::__construct($options);
$this->extension = $extension;
$this->method = $method;
}
public function compile()
{
return
sprintf('$this->env->getExtension(\'%s\')->%s',
\get_class($this->extension), $this->method);
}
}
Filter/Node.php000064400000001560151160705100007365 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
@trigger_error('The Twig_Filter_Node class is deprecated since version
1.12 and will be removed in 2.0. Use \Twig\TwigFilter instead.',
E_USER_DEPRECATED);
/**
* Represents a template filter as a node.
*
* Use \Twig\TwigFilter instead.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
class Twig_Filter_Node extends Twig_Filter
{
protected $class;
public function __construct($class, array $options = [])
{
parent::__construct($options);
$this->class = $class;
}
public function getClass()
{
return $this->class;
}
public function compile()
{
}
}
Filter.php000064400000003717151160705100006506 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\Node\Node;
@trigger_error('The Twig_Filter class is deprecated since version 1.12
and will be removed in 2.0. Use \Twig\TwigFilter instead.',
E_USER_DEPRECATED);
/**
* Represents a template filter.
*
* Use \Twig\TwigFilter instead.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
abstract class Twig_Filter implements Twig_FilterInterface,
Twig_FilterCallableInterface
{
protected $options;
protected $arguments = [];
public function __construct(array $options = [])
{
$this->options = array_merge([
'needs_environment' => false,
'needs_context' => false,
'pre_escape' => null,
'preserves_safety' => null,
'callable' => null,
], $options);
}
public function setArguments($arguments)
{
$this->arguments = $arguments;
}
public function getArguments()
{
return $this->arguments;
}
public function needsEnvironment()
{
return $this->options['needs_environment'];
}
public function needsContext()
{
return $this->options['needs_context'];
}
public function getSafe(Node $filterArgs)
{
if (isset($this->options['is_safe'])) {
return $this->options['is_safe'];
}
if (isset($this->options['is_safe_callback'])) {
return
\call_user_func($this->options['is_safe_callback'],
$filterArgs);
}
}
public function getPreservesSafety()
{
return $this->options['preserves_safety'];
}
public function getPreEscape()
{
return $this->options['pre_escape'];
}
public function getCallable()
{
return $this->options['callable'];
}
}
FilterCallableInterface.php000064400000000726151160705100011744
0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
/**
* Represents a callable template filter.
*
* Use \Twig\TwigFilter instead.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
interface Twig_FilterCallableInterface
{
public function getCallable();
}
FilterInterface.php000064400000001533151160705100010321 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\Node\Node;
/**
* Represents a template filter.
*
* Use \Twig\TwigFilter instead.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
interface Twig_FilterInterface
{
/**
* Compiles a filter.
*
* @return string The PHP code for the filter
*/
public function compile();
public function needsEnvironment();
public function needsContext();
public function getSafe(Node $filterArgs);
public function getPreservesSafety();
public function getPreEscape();
public function setArguments($arguments);
public function getArguments();
}
Function/Function.php000064400000001650151160705100010625 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
* (c) Arnaud Le Blanc
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
@trigger_error('The Twig_Function_Function class is deprecated since
version 1.12 and will be removed in 2.0. Use \Twig\TwigFunction
instead.', E_USER_DEPRECATED);
/**
* Represents a function template function.
*
* Use \Twig\TwigFunction instead.
*
* @author Arnaud Le Blanc <arnaud.lb@gmail.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
class Twig_Function_Function extends Twig_Function
{
protected $function;
public function __construct($function, array $options = [])
{
$options['callable'] = $function;
parent::__construct($options);
$this->function = $function;
}
public function compile()
{
return $this->function;
}
}
Function/Method.php000064400000002173151160705100010261 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
* (c) Arnaud Le Blanc
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\Extension\ExtensionInterface;
@trigger_error('The Twig_Function_Method class is deprecated since
version 1.12 and will be removed in 2.0. Use \Twig\TwigFunction
instead.', E_USER_DEPRECATED);
/**
* Represents a method template function.
*
* Use \Twig\TwigFunction instead.
*
* @author Arnaud Le Blanc <arnaud.lb@gmail.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
class Twig_Function_Method extends Twig_Function
{
protected $extension;
protected $method;
public function __construct(ExtensionInterface $extension, $method,
array $options = [])
{
$options['callable'] = [$extension, $method];
parent::__construct($options);
$this->extension = $extension;
$this->method = $method;
}
public function compile()
{
return
sprintf('$this->env->getExtension(\'%s\')->%s',
\get_class($this->extension), $this->method);
}
}
Function/Node.php000064400000001574151160705100007732 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
@trigger_error('The Twig_Function_Node class is deprecated since
version 1.12 and will be removed in 2.0. Use \Twig\TwigFunction
instead.', E_USER_DEPRECATED);
/**
* Represents a template function as a node.
*
* Use \Twig\TwigFunction instead.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
class Twig_Function_Node extends Twig_Function
{
protected $class;
public function __construct($class, array $options = [])
{
parent::__construct($options);
$this->class = $class;
}
public function getClass()
{
return $this->class;
}
public function compile()
{
}
}
Function.php000064400000003345151160705100007043 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\Node\Node;
@trigger_error('The Twig_Function class is deprecated since version
1.12 and will be removed in 2.0. Use \Twig\TwigFunction instead.',
E_USER_DEPRECATED);
/**
* Represents a template function.
*
* Use \Twig\TwigFunction instead.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
abstract class Twig_Function implements Twig_FunctionInterface,
Twig_FunctionCallableInterface
{
protected $options;
protected $arguments = [];
public function __construct(array $options = [])
{
$this->options = array_merge([
'needs_environment' => false,
'needs_context' => false,
'callable' => null,
], $options);
}
public function setArguments($arguments)
{
$this->arguments = $arguments;
}
public function getArguments()
{
return $this->arguments;
}
public function needsEnvironment()
{
return $this->options['needs_environment'];
}
public function needsContext()
{
return $this->options['needs_context'];
}
public function getSafe(Node $functionArgs)
{
if (isset($this->options['is_safe'])) {
return $this->options['is_safe'];
}
if (isset($this->options['is_safe_callback'])) {
return
\call_user_func($this->options['is_safe_callback'],
$functionArgs);
}
return [];
}
public function getCallable()
{
return $this->options['callable'];
}
}
FunctionCallableInterface.php000064400000000734151160705100012303
0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
/**
* Represents a callable template function.
*
* Use \Twig\TwigFunction instead.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
interface Twig_FunctionCallableInterface
{
public function getCallable();
}
FunctionInterface.php000064400000001454151160705100010663 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
* (c) Arnaud Le Blanc
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\Node\Node;
/**
* Represents a template function.
*
* Use \Twig\TwigFunction instead.
*
* @author Arnaud Le Blanc <arnaud.lb@gmail.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
interface Twig_FunctionInterface
{
/**
* Compiles a function.
*
* @return string The PHP code for the function
*/
public function compile();
public function needsEnvironment();
public function needsContext();
public function getSafe(Node $filterArgs);
public function setArguments($arguments);
public function getArguments();
}
Lexer.php000064400000000164151160705100006331 0ustar00<?php
use Twig\Lexer;
class_exists('Twig\Lexer');
if (\false) {
class Twig_Lexer extends Lexer
{
}
}
LexerInterface.php000064400000001432151160705100010151 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\Error\SyntaxError;
use Twig\Source;
use Twig\TokenStream;
/**
* Interface implemented by lexer classes.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 3.0)
*/
interface Twig_LexerInterface
{
/**
* Tokenizes a source code.
*
* @param string|Source $code The source code
* @param string $name A unique identifier for the source code
*
* @return TokenStream
*
* @throws SyntaxError When the code is syntactically wrong
*/
public function tokenize($code, $name = null);
}
Loader/Array.php000064400000000233151160705100007533 0ustar00<?php
use Twig\Loader\ArrayLoader;
class_exists('Twig\Loader\ArrayLoader');
if (\false) {
class Twig_Loader_Array extends ArrayLoader
{
}
}
Loader/Chain.php000064400000000233151160705100007477 0ustar00<?php
use Twig\Loader\ChainLoader;
class_exists('Twig\Loader\ChainLoader');
if (\false) {
class Twig_Loader_Chain extends ChainLoader
{
}
}
Loader/Filesystem.php000064400000000257151160705100010607 0ustar00<?php
use Twig\Loader\FilesystemLoader;
class_exists('Twig\Loader\FilesystemLoader');
if (\false) {
class Twig_Loader_Filesystem extends FilesystemLoader
{
}
}
Loader/String.php000064400000003367151160705100007736 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\Loader\ExistsLoaderInterface;
use Twig\Loader\LoaderInterface;
use Twig\Loader\SourceContextLoaderInterface;
use Twig\Source;
@trigger_error('The Twig_Loader_String class is deprecated since
version 1.18.1 and will be removed in 2.0. Use
"Twig\Loader\ArrayLoader" instead or
"Twig\Environment::createTemplate()".', E_USER_DEPRECATED);
/**
* Loads a template from a string.
*
* This loader should NEVER be used. It only exists for Twig internal
purposes.
*
* When using this loader with a cache mechanism, you should know that a
new cache
* key is generated each time a template content "changes" (the
cache key being the
* source code of the template). If you don't want to see your cache
grows out of
* control, you need to take care of clearing the old cache file by
yourself.
*
* @deprecated since 1.18.1 (to be removed in 2.0)
*
* @internal
*
* @author Fabien Potencier <fabien@symfony.com>
*/
class Twig_Loader_String implements LoaderInterface, ExistsLoaderInterface,
SourceContextLoaderInterface
{
public function getSource($name)
{
@trigger_error(sprintf('Calling "getSource" on
"%s" is deprecated since 1.27. Use getSourceContext()
instead.', \get_class($this)), E_USER_DEPRECATED);
return $name;
}
public function getSourceContext($name)
{
return new Source($name, $name);
}
public function exists($name)
{
return true;
}
public function getCacheKey($name)
{
return $name;
}
public function isFresh($name, $time)
{
return true;
}
}
LoaderInterface.php000064400000000252151160705100010277 0ustar00<?php
use Twig\Loader\LoaderInterface;
class_exists('Twig\Loader\LoaderInterface');
if (\false) {
class Twig_LoaderInterface extends LoaderInterface
{
}
}
Markup.php000064400000000170151160705100006506 0ustar00<?php
use Twig\Markup;
class_exists('Twig\Markup');
if (\false) {
class Twig_Markup extends Markup
{
}
}
Node/AutoEscape.php000064400000000243151160705100010166 0ustar00<?php
use Twig\Node\AutoEscapeNode;
class_exists('Twig\Node\AutoEscapeNode');
if (\false) {
class Twig_Node_AutoEscape extends AutoEscapeNode
{
}
}
Node/Block.php000064400000000217151160705100007170 0ustar00<?php
use Twig\Node\BlockNode;
class_exists('Twig\Node\BlockNode');
if (\false) {
class Twig_Node_Block extends BlockNode
{
}
}
Node/BlockReference.php000064400000000263151160705100011010
0ustar00<?php
use Twig\Node\BlockReferenceNode;
class_exists('Twig\Node\BlockReferenceNode');
if (\false) {
class Twig_Node_BlockReference extends BlockReferenceNode
{
}
}
Node/Body.php000064400000000213151160705100007027 0ustar00<?php
use Twig\Node\BodyNode;
class_exists('Twig\Node\BodyNode');
if (\false) {
class Twig_Node_Body extends BodyNode
{
}
}
Node/CheckSecurity.php000064400000000257151160705100010707 0ustar00<?php
use Twig\Node\CheckSecurityNode;
class_exists('Twig\Node\CheckSecurityNode');
if (\false) {
class Twig_Node_CheckSecurity extends CheckSecurityNode
{
}
}
Node/Deprecated.php000064400000000243151160705100010175 0ustar00<?php
use Twig\Node\DeprecatedNode;
class_exists('Twig\Node\DeprecatedNode');
if (\false) {
class Twig_Node_Deprecated extends DeprecatedNode
{
}
}
Node/Do.php000064400000000203151160705100006473 0ustar00<?php
use Twig\Node\DoNode;
class_exists('Twig\Node\DoNode');
if (\false) {
class Twig_Node_Do extends DoNode
{
}
}
Node/Embed.php000064400000000217151160705100007152 0ustar00<?php
use Twig\Node\EmbedNode;
class_exists('Twig\Node\EmbedNode');
if (\false) {
class Twig_Node_Embed extends EmbedNode
{
}
}
Node/Expression/Array.php000064400000000302151160705100011346
0ustar00<?php
use Twig\Node\Expression\ArrayExpression;
class_exists('Twig\Node\Expression\ArrayExpression');
if (\false) {
class Twig_Node_Expression_Array extends ArrayExpression
{
}
}
Node/Expression/AssignName.php000064400000000326151160705100012323
0ustar00<?php
use Twig\Node\Expression\AssignNameExpression;
class_exists('Twig\Node\Expression\AssignNameExpression');
if (\false) {
class Twig_Node_Expression_AssignName extends AssignNameExpression
{
}
}
Node/Expression/Binary/Add.php000064400000000303151160705100012205
0ustar00<?php
use Twig\Node\Expression\Binary\AddBinary;
class_exists('Twig\Node\Expression\Binary\AddBinary');
if (\false) {
class Twig_Node_Expression_Binary_Add extends AddBinary
{
}
}
Node/Expression/Binary/And.php000064400000000303151160705100012217
0ustar00<?php
use Twig\Node\Expression\Binary\AndBinary;
class_exists('Twig\Node\Expression\Binary\AndBinary');
if (\false) {
class Twig_Node_Expression_Binary_And extends AndBinary
{
}
}
Node/Expression/Binary/BitwiseAnd.php000064400000000337151160705100013555
0ustar00<?php
use Twig\Node\Expression\Binary\BitwiseAndBinary;
class_exists('Twig\Node\Expression\Binary\BitwiseAndBinary');
if (\false) {
class Twig_Node_Expression_Binary_BitwiseAnd extends BitwiseAndBinary
{
}
}
Node/Expression/Binary/BitwiseOr.php000064400000000333151160705100013427
0ustar00<?php
use Twig\Node\Expression\Binary\BitwiseOrBinary;
class_exists('Twig\Node\Expression\Binary\BitwiseOrBinary');
if (\false) {
class Twig_Node_Expression_Binary_BitwiseOr extends BitwiseOrBinary
{
}
}
Node/Expression/Binary/BitwiseXor.php000064400000000337151160705100013623
0ustar00<?php
use Twig\Node\Expression\Binary\BitwiseXorBinary;
class_exists('Twig\Node\Expression\Binary\BitwiseXorBinary');
if (\false) {
class Twig_Node_Expression_Binary_BitwiseXor extends BitwiseXorBinary
{
}
}
Node/Expression/Binary/Concat.php000064400000000317151160705100012731
0ustar00<?php
use Twig\Node\Expression\Binary\ConcatBinary;
class_exists('Twig\Node\Expression\Binary\ConcatBinary');
if (\false) {
class Twig_Node_Expression_Binary_Concat extends ConcatBinary
{
}
}
Node/Expression/Binary/Div.php000064400000000303151160705100012237
0ustar00<?php
use Twig\Node\Expression\Binary\DivBinary;
class_exists('Twig\Node\Expression\Binary\DivBinary');
if (\false) {
class Twig_Node_Expression_Binary_Div extends DivBinary
{
}
}
Node/Expression/Binary/EndsWith.php000064400000000327151160705100013250
0ustar00<?php
use Twig\Node\Expression\Binary\EndsWithBinary;
class_exists('Twig\Node\Expression\Binary\EndsWithBinary');
if (\false) {
class Twig_Node_Expression_Binary_EndsWith extends EndsWithBinary
{
}
}
Node/Expression/Binary/Equal.php000064400000000313151160705100012565
0ustar00<?php
use Twig\Node\Expression\Binary\EqualBinary;
class_exists('Twig\Node\Expression\Binary\EqualBinary');
if (\false) {
class Twig_Node_Expression_Binary_Equal extends EqualBinary
{
}
}
Node/Expression/Binary/FloorDiv.php000064400000000327151160705100013247
0ustar00<?php
use Twig\Node\Expression\Binary\FloorDivBinary;
class_exists('Twig\Node\Expression\Binary\FloorDivBinary');
if (\false) {
class Twig_Node_Expression_Binary_FloorDiv extends FloorDivBinary
{
}
}
Node/Expression/Binary/Greater.php000064400000000323151160705100013110
0ustar00<?php
use Twig\Node\Expression\Binary\GreaterBinary;
class_exists('Twig\Node\Expression\Binary\GreaterBinary');
if (\false) {
class Twig_Node_Expression_Binary_Greater extends GreaterBinary
{
}
}
Node/Expression/Binary/GreaterEqual.php000064400000000347151160705100014106
0ustar00<?php
use Twig\Node\Expression\Binary\GreaterEqualBinary;
class_exists('Twig\Node\Expression\Binary\GreaterEqualBinary');
if (\false) {
class Twig_Node_Expression_Binary_GreaterEqual extends
GreaterEqualBinary
{
}
}
Node/Expression/Binary/In.php000064400000000277151160705100012075
0ustar00<?php
use Twig\Node\Expression\Binary\InBinary;
class_exists('Twig\Node\Expression\Binary\InBinary');
if (\false) {
class Twig_Node_Expression_Binary_In extends InBinary
{
}
}
Node/Expression/Binary/Less.php000064400000000307151160705100012427
0ustar00<?php
use Twig\Node\Expression\Binary\LessBinary;
class_exists('Twig\Node\Expression\Binary\LessBinary');
if (\false) {
class Twig_Node_Expression_Binary_Less extends LessBinary
{
}
}
Node/Expression/Binary/LessEqual.php000064400000000333151160705110013417
0ustar00<?php
use Twig\Node\Expression\Binary\LessEqualBinary;
class_exists('Twig\Node\Expression\Binary\LessEqualBinary');
if (\false) {
class Twig_Node_Expression_Binary_LessEqual extends LessEqualBinary
{
}
}
Node/Expression/Binary/Matches.php000064400000000323151160705110013104
0ustar00<?php
use Twig\Node\Expression\Binary\MatchesBinary;
class_exists('Twig\Node\Expression\Binary\MatchesBinary');
if (\false) {
class Twig_Node_Expression_Binary_Matches extends MatchesBinary
{
}
}
Node/Expression/Binary/Mod.php000064400000000303151160705110012235
0ustar00<?php
use Twig\Node\Expression\Binary\ModBinary;
class_exists('Twig\Node\Expression\Binary\ModBinary');
if (\false) {
class Twig_Node_Expression_Binary_Mod extends ModBinary
{
}
}
Node/Expression/Binary/Mul.php000064400000000303151160705110012253
0ustar00<?php
use Twig\Node\Expression\Binary\MulBinary;
class_exists('Twig\Node\Expression\Binary\MulBinary');
if (\false) {
class Twig_Node_Expression_Binary_Mul extends MulBinary
{
}
}
Node/Expression/Binary/NotEqual.php000064400000000327151160705110013254
0ustar00<?php
use Twig\Node\Expression\Binary\NotEqualBinary;
class_exists('Twig\Node\Expression\Binary\NotEqualBinary');
if (\false) {
class Twig_Node_Expression_Binary_NotEqual extends NotEqualBinary
{
}
}
Node/Expression/Binary/NotIn.php000064400000000313151160705110012546
0ustar00<?php
use Twig\Node\Expression\Binary\NotInBinary;
class_exists('Twig\Node\Expression\Binary\NotInBinary');
if (\false) {
class Twig_Node_Expression_Binary_NotIn extends NotInBinary
{
}
}
Node/Expression/Binary/Or.php000064400000000277151160705110012110
0ustar00<?php
use Twig\Node\Expression\Binary\OrBinary;
class_exists('Twig\Node\Expression\Binary\OrBinary');
if (\false) {
class Twig_Node_Expression_Binary_Or extends OrBinary
{
}
}
Node/Expression/Binary/Power.php000064400000000313151160705110012613
0ustar00<?php
use Twig\Node\Expression\Binary\PowerBinary;
class_exists('Twig\Node\Expression\Binary\PowerBinary');
if (\false) {
class Twig_Node_Expression_Binary_Power extends PowerBinary
{
}
}
Node/Expression/Binary/Range.php000064400000000313151160705110012553
0ustar00<?php
use Twig\Node\Expression\Binary\RangeBinary;
class_exists('Twig\Node\Expression\Binary\RangeBinary');
if (\false) {
class Twig_Node_Expression_Binary_Range extends RangeBinary
{
}
}
Node/Expression/Binary/StartsWith.php000064400000000337151160705110013641
0ustar00<?php
use Twig\Node\Expression\Binary\StartsWithBinary;
class_exists('Twig\Node\Expression\Binary\StartsWithBinary');
if (\false) {
class Twig_Node_Expression_Binary_StartsWith extends StartsWithBinary
{
}
}
Node/Expression/Binary/Sub.php000064400000000303151160705110012247
0ustar00<?php
use Twig\Node\Expression\Binary\SubBinary;
class_exists('Twig\Node\Expression\Binary\SubBinary');
if (\false) {
class Twig_Node_Expression_Binary_Sub extends SubBinary
{
}
}
Node/Expression/Binary.php000064400000000316151160705110011522
0ustar00<?php
use Twig\Node\Expression\Binary\AbstractBinary;
class_exists('Twig\Node\Expression\Binary\AbstractBinary');
if (\false) {
class Twig_Node_Expression_Binary extends AbstractBinary
{
}
}
Node/Expression/BlockReference.php000064400000000346151160705110013152
0ustar00<?php
use Twig\Node\Expression\BlockReferenceExpression;
class_exists('Twig\Node\Expression\BlockReferenceExpression');
if (\false) {
class Twig_Node_Expression_BlockReference extends
BlockReferenceExpression
{
}
}
Node/Expression/Call.php000064400000000276151160705110011156
0ustar00<?php
use Twig\Node\Expression\CallExpression;
class_exists('Twig\Node\Expression\CallExpression');
if (\false) {
class Twig_Node_Expression_Call extends CallExpression
{
}
}
Node/Expression/Conditional.php000064400000000332151160705110012537
0ustar00<?php
use Twig\Node\Expression\ConditionalExpression;
class_exists('Twig\Node\Expression\ConditionalExpression');
if (\false) {
class Twig_Node_Expression_Conditional extends ConditionalExpression
{
}
}
Node/Expression/Constant.php000064400000000316151160705110012067
0ustar00<?php
use Twig\Node\Expression\ConstantExpression;
class_exists('Twig\Node\Expression\ConstantExpression');
if (\false) {
class Twig_Node_Expression_Constant extends ConstantExpression
{
}
}
Node/Expression/ExtensionReference.php000064400000001663151160705110014077
0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\Compiler;
use Twig\Node\Expression\AbstractExpression;
@trigger_error('The Twig_Node_Expression_ExtensionReference class is
deprecated since version 1.23 and will be removed in 2.0.',
E_USER_DEPRECATED);
/**
* Represents an extension call node.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.23 and will be removed in 2.0.
*/
class Twig_Node_Expression_ExtensionReference extends AbstractExpression
{
public function __construct($name, $lineno, $tag = null)
{
parent::__construct([], ['name' => $name], $lineno,
$tag);
}
public function compile(Compiler $compiler)
{
$compiler->raw(sprintf("\$this->env->getExtension('%s')",
$this->getAttribute('name')));
}
}
Node/Expression/Filter/Default.php000064400000000323151160705110013105
0ustar00<?php
use Twig\Node\Expression\Filter\DefaultFilter;
class_exists('Twig\Node\Expression\Filter\DefaultFilter');
if (\false) {
class Twig_Node_Expression_Filter_Default extends DefaultFilter
{
}
}
Node/Expression/Filter.php000064400000000306151160705110011522
0ustar00<?php
use Twig\Node\Expression\FilterExpression;
class_exists('Twig\Node\Expression\FilterExpression');
if (\false) {
class Twig_Node_Expression_Filter extends FilterExpression
{
}
}
Node/Expression/Function.php000064400000000316151160705110012063
0ustar00<?php
use Twig\Node\Expression\FunctionExpression;
class_exists('Twig\Node\Expression\FunctionExpression');
if (\false) {
class Twig_Node_Expression_Function extends FunctionExpression
{
}
}
Node/Expression/GetAttr.php000064400000000312151160705110011644
0ustar00<?php
use Twig\Node\Expression\GetAttrExpression;
class_exists('Twig\Node\Expression\GetAttrExpression');
if (\false) {
class Twig_Node_Expression_GetAttr extends GetAttrExpression
{
}
}
Node/Expression/MethodCall.php000064400000000326151160705110012313
0ustar00<?php
use Twig\Node\Expression\MethodCallExpression;
class_exists('Twig\Node\Expression\MethodCallExpression');
if (\false) {
class Twig_Node_Expression_MethodCall extends MethodCallExpression
{
}
}
Node/Expression/Name.php000064400000000276151160705110011163
0ustar00<?php
use Twig\Node\Expression\NameExpression;
class_exists('Twig\Node\Expression\NameExpression');
if (\false) {
class Twig_Node_Expression_Name extends NameExpression
{
}
}
Node/Expression/NullCoalesce.php000064400000000336151160705110012651
0ustar00<?php
use Twig\Node\Expression\NullCoalesceExpression;
class_exists('Twig\Node\Expression\NullCoalesceExpression');
if (\false) {
class Twig_Node_Expression_NullCoalesce extends NullCoalesceExpression
{
}
}
Node/Expression/Parent.php000064400000000306151160705110011526
0ustar00<?php
use Twig\Node\Expression\ParentExpression;
class_exists('Twig\Node\Expression\ParentExpression');
if (\false) {
class Twig_Node_Expression_Parent extends ParentExpression
{
}
}
Node/Expression/TempName.php000064400000000316151160705110012004
0ustar00<?php
use Twig\Node\Expression\TempNameExpression;
class_exists('Twig\Node\Expression\TempNameExpression');
if (\false) {
class Twig_Node_Expression_TempName extends TempNameExpression
{
}
}
Node/Expression/Test/Constant.php000064400000000313151160705110013003
0ustar00<?php
use Twig\Node\Expression\Test\ConstantTest;
class_exists('Twig\Node\Expression\Test\ConstantTest');
if (\false) {
class Twig_Node_Expression_Test_Constant extends ConstantTest
{
}
}
Node/Expression/Test/Defined.php000064400000000307151160705110012553
0ustar00<?php
use Twig\Node\Expression\Test\DefinedTest;
class_exists('Twig\Node\Expression\Test\DefinedTest');
if (\false) {
class Twig_Node_Expression_Test_Defined extends DefinedTest
{
}
}
Node/Expression/Test/Divisibleby.php000064400000000327151160705110013464
0ustar00<?php
use Twig\Node\Expression\Test\DivisiblebyTest;
class_exists('Twig\Node\Expression\Test\DivisiblebyTest');
if (\false) {
class Twig_Node_Expression_Test_Divisibleby extends DivisiblebyTest
{
}
}
Node/Expression/Test/Even.php000064400000000273151160705110012114
0ustar00<?php
use Twig\Node\Expression\Test\EvenTest;
class_exists('Twig\Node\Expression\Test\EvenTest');
if (\false) {
class Twig_Node_Expression_Test_Even extends EvenTest
{
}
}
Node/Expression/Test/Null.php000064400000000273151160705110012131
0ustar00<?php
use Twig\Node\Expression\Test\NullTest;
class_exists('Twig\Node\Expression\Test\NullTest');
if (\false) {
class Twig_Node_Expression_Test_Null extends NullTest
{
}
}
Node/Expression/Test/Odd.php000064400000000267151160705110011730
0ustar00<?php
use Twig\Node\Expression\Test\OddTest;
class_exists('Twig\Node\Expression\Test\OddTest');
if (\false) {
class Twig_Node_Expression_Test_Odd extends OddTest
{
}
}
Node/Expression/Test/Sameas.php000064400000000303151160705110012422
0ustar00<?php
use Twig\Node\Expression\Test\SameasTest;
class_exists('Twig\Node\Expression\Test\SameasTest');
if (\false) {
class Twig_Node_Expression_Test_Sameas extends SameasTest
{
}
}
Node/Expression/Test.php000064400000000276151160705110011222
0ustar00<?php
use Twig\Node\Expression\TestExpression;
class_exists('Twig\Node\Expression\TestExpression');
if (\false) {
class Twig_Node_Expression_Test extends TestExpression
{
}
}
Node/Expression/Unary/Neg.php000064400000000275151160705110012111
0ustar00<?php
use Twig\Node\Expression\Unary\NegUnary;
class_exists('Twig\Node\Expression\Unary\NegUnary');
if (\false) {
class Twig_Node_Expression_Unary_Neg extends NegUnary
{
}
}
Node/Expression/Unary/Not.php000064400000000275151160705110012140
0ustar00<?php
use Twig\Node\Expression\Unary\NotUnary;
class_exists('Twig\Node\Expression\Unary\NotUnary');
if (\false) {
class Twig_Node_Expression_Unary_Not extends NotUnary
{
}
}
Node/Expression/Unary/Pos.php000064400000000275151160705110012141
0ustar00<?php
use Twig\Node\Expression\Unary\PosUnary;
class_exists('Twig\Node\Expression\Unary\PosUnary');
if (\false) {
class Twig_Node_Expression_Unary_Pos extends PosUnary
{
}
}
Node/Expression/Unary.php000064400000000310151160705110011366
0ustar00<?php
use Twig\Node\Expression\Unary\AbstractUnary;
class_exists('Twig\Node\Expression\Unary\AbstractUnary');
if (\false) {
class Twig_Node_Expression_Unary extends AbstractUnary
{
}
}
Node/Expression.php000064400000000305151160705110010274 0ustar00<?php
use Twig\Node\Expression\AbstractExpression;
class_exists('Twig\Node\Expression\AbstractExpression');
if (\false) {
class Twig_Node_Expression extends AbstractExpression
{
}
}
Node/Flush.php000064400000000217151160705110007220 0ustar00<?php
use Twig\Node\FlushNode;
class_exists('Twig\Node\FlushNode');
if (\false) {
class Twig_Node_Flush extends FlushNode
{
}
}
Node/For.php000064400000000207151160705110006664 0ustar00<?php
use Twig\Node\ForNode;
class_exists('Twig\Node\ForNode');
if (\false) {
class Twig_Node_For extends ForNode
{
}
}
Node/ForLoop.php000064400000000227151160705110007520 0ustar00<?php
use Twig\Node\ForLoopNode;
class_exists('Twig\Node\ForLoopNode');
if (\false) {
class Twig_Node_ForLoop extends ForLoopNode
{
}
}
Node/If.php000064400000000203151160705120006471 0ustar00<?php
use Twig\Node\IfNode;
class_exists('Twig\Node\IfNode');
if (\false) {
class Twig_Node_If extends IfNode
{
}
}
Node/Import.php000064400000000223151160705120007407 0ustar00<?php
use Twig\Node\ImportNode;
class_exists('Twig\Node\ImportNode');
if (\false) {
class Twig_Node_Import extends ImportNode
{
}
}
Node/Include.php000064400000000227151160705120007524 0ustar00<?php
use Twig\Node\IncludeNode;
class_exists('Twig\Node\IncludeNode');
if (\false) {
class Twig_Node_Include extends IncludeNode
{
}
}
Node/Macro.php000064400000000217151160705120007201 0ustar00<?php
use Twig\Node\MacroNode;
class_exists('Twig\Node\MacroNode');
if (\false) {
class Twig_Node_Macro extends MacroNode
{
}
}
Node/Module.php000064400000000223151160705120007362 0ustar00<?php
use Twig\Node\ModuleNode;
class_exists('Twig\Node\ModuleNode');
if (\false) {
class Twig_Node_Module extends ModuleNode
{
}
}
Node/Print.php000064400000000217151160705120007234 0ustar00<?php
use Twig\Node\PrintNode;
class_exists('Twig\Node\PrintNode');
if (\false) {
class Twig_Node_Print extends PrintNode
{
}
}
Node/Sandbox.php000064400000000227151160705120007537 0ustar00<?php
use Twig\Node\SandboxNode;
class_exists('Twig\Node\SandboxNode');
if (\false) {
class Twig_Node_Sandbox extends SandboxNode
{
}
}
Node/SandboxedPrint.php000064400000000263151160705120011065
0ustar00<?php
use Twig\Node\SandboxedPrintNode;
class_exists('Twig\Node\SandboxedPrintNode');
if (\false) {
class Twig_Node_SandboxedPrint extends SandboxedPrintNode
{
}
}
Node/Set.php000064400000000207151160705120006672 0ustar00<?php
use Twig\Node\SetNode;
class_exists('Twig\Node\SetNode');
if (\false) {
class Twig_Node_Set extends SetNode
{
}
}
Node/SetTemp.php000064400000000227151160705120007522 0ustar00<?php
use Twig\Node\SetTempNode;
class_exists('Twig\Node\SetTempNode');
if (\false) {
class Twig_Node_SetTemp extends SetTempNode
{
}
}
Node/Spaceless.php000064400000000237151160705120010064 0ustar00<?php
use Twig\Node\SpacelessNode;
class_exists('Twig\Node\SpacelessNode');
if (\false) {
class Twig_Node_Spaceless extends SpacelessNode
{
}
}
Node/Text.php000064400000000213151160705120007060 0ustar00<?php
use Twig\Node\TextNode;
class_exists('Twig\Node\TextNode');
if (\false) {
class Twig_Node_Text extends TextNode
{
}
}
Node/With.php000064400000000213151160705120007047 0ustar00<?php
use Twig\Node\WithNode;
class_exists('Twig\Node\WithNode');
if (\false) {
class Twig_Node_With extends WithNode
{
}
}
Node.php000064400000000172151160705120006140 0ustar00<?php
use Twig\Node\Node;
class_exists('Twig\Node\Node');
if (\false) {
class Twig_Node extends Node
{
}
}
NodeCaptureInterface.php000064400000000272151160705120011306
0ustar00<?php
use Twig\Node\NodeCaptureInterface;
class_exists('Twig\Node\NodeCaptureInterface');
if (\false) {
class Twig_NodeCaptureInterface extends NodeCaptureInterface
{
}
}
NodeInterface.php000064400000001241151160705120007757 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\Compiler;
/**
* Represents a node in the AST.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 3.0)
*/
interface Twig_NodeInterface extends \Countable, \IteratorAggregate
{
/**
* Compiles the node to PHP.
*/
public function compile(Compiler $compiler);
/**
* @deprecated since 1.27 (to be removed in 2.0)
*/
public function getLine();
public function getNodeTag();
}
NodeOutputInterface.php000064400000000266151160705120011206
0ustar00<?php
use Twig\Node\NodeOutputInterface;
class_exists('Twig\Node\NodeOutputInterface');
if (\false) {
class Twig_NodeOutputInterface extends NodeOutputInterface
{
}
}
NodeTraverser.php000064400000000224151160705120010034 0ustar00<?php
use Twig\NodeTraverser;
class_exists('Twig\NodeTraverser');
if (\false) {
class Twig_NodeTraverser extends NodeTraverser
{
}
}
NodeVisitor/Escaper.php000064400000000301151160705120011074
0ustar00<?php
use Twig\NodeVisitor\EscaperNodeVisitor;
class_exists('Twig\NodeVisitor\EscaperNodeVisitor');
if (\false) {
class Twig_NodeVisitor_Escaper extends EscaperNodeVisitor
{
}
}
NodeVisitor/Optimizer.php000064400000000311151160705120011475
0ustar00<?php
use Twig\NodeVisitor\OptimizerNodeVisitor;
class_exists('Twig\NodeVisitor\OptimizerNodeVisitor');
if (\false) {
class Twig_NodeVisitor_Optimizer extends OptimizerNodeVisitor
{
}
}
NodeVisitor/SafeAnalysis.php000064400000000325151160705120012102
0ustar00<?php
use Twig\NodeVisitor\SafeAnalysisNodeVisitor;
class_exists('Twig\NodeVisitor\SafeAnalysisNodeVisitor');
if (\false) {
class Twig_NodeVisitor_SafeAnalysis extends SafeAnalysisNodeVisitor
{
}
}
NodeVisitor/Sandbox.php000064400000000301151160705120011110
0ustar00<?php
use Twig\NodeVisitor\SandboxNodeVisitor;
class_exists('Twig\NodeVisitor\SandboxNodeVisitor');
if (\false) {
class Twig_NodeVisitor_Sandbox extends SandboxNodeVisitor
{
}
}
NodeVisitorInterface.php000064400000000310151160705120011333
0ustar00<?php
use Twig\NodeVisitor\NodeVisitorInterface;
class_exists('Twig\NodeVisitor\NodeVisitorInterface');
if (\false) {
class Twig_NodeVisitorInterface extends NodeVisitorInterface
{
}
}
Parser.php000064400000000170151160705120006505 0ustar00<?php
use Twig\Parser;
class_exists('Twig\Parser');
if (\false) {
class Twig_Parser extends Parser
{
}
}
ParserInterface.php000064400000001305151160705120010327 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\Error\SyntaxError;
use Twig\Node\ModuleNode;
use Twig\TokenStream;
/**
* Interface implemented by parser classes.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 3.0)
*/
interface Twig_ParserInterface
{
/**
* Converts a token stream to a node tree.
*
* @return ModuleNode
*
* @throws SyntaxError When the token stream is syntactically or
semantically wrong
*/
public function parse(TokenStream $stream);
}
Profiler/Dumper/Base.php000064400000000262151160705120011143
0ustar00<?php
use Twig\Profiler\Dumper\BaseDumper;
class_exists('Twig\Profiler\Dumper\BaseDumper');
if (\false) {
class Twig_Profiler_Dumper_Base extends BaseDumper
{
}
}
Profiler/Dumper/Blackfire.php000064400000000306151160705120012152
0ustar00<?php
use Twig\Profiler\Dumper\BlackfireDumper;
class_exists('Twig\Profiler\Dumper\BlackfireDumper');
if (\false) {
class Twig_Profiler_Dumper_Blackfire extends BlackfireDumper
{
}
}
Profiler/Dumper/Html.php000064400000000262151160705120011175
0ustar00<?php
use Twig\Profiler\Dumper\HtmlDumper;
class_exists('Twig\Profiler\Dumper\HtmlDumper');
if (\false) {
class Twig_Profiler_Dumper_Html extends HtmlDumper
{
}
}
Profiler/Dumper/Text.php000064400000000262151160705120011215
0ustar00<?php
use Twig\Profiler\Dumper\TextDumper;
class_exists('Twig\Profiler\Dumper\TextDumper');
if (\false) {
class Twig_Profiler_Dumper_Text extends TextDumper
{
}
}
Profiler/Node/EnterProfile.php000064400000000306151160705120012317
0ustar00<?php
use Twig\Profiler\Node\EnterProfileNode;
class_exists('Twig\Profiler\Node\EnterProfileNode');
if (\false) {
class Twig_Profiler_Node_EnterProfile extends EnterProfileNode
{
}
}
Profiler/Node/LeaveProfile.php000064400000000306151160705120012276
0ustar00<?php
use Twig\Profiler\Node\LeaveProfileNode;
class_exists('Twig\Profiler\Node\LeaveProfileNode');
if (\false) {
class Twig_Profiler_Node_LeaveProfile extends LeaveProfileNode
{
}
}
Profiler/NodeVisitor/Profiler.php000064400000000340151160705120013061
0ustar00<?php
use Twig\Profiler\NodeVisitor\ProfilerNodeVisitor;
class_exists('Twig\Profiler\NodeVisitor\ProfilerNodeVisitor');
if (\false) {
class Twig_Profiler_NodeVisitor_Profiler extends ProfilerNodeVisitor
{
}
}
Profiler/Profile.php000064400000000227151160705120010436 0ustar00<?php
use Twig\Profiler\Profile;
class_exists('Twig\Profiler\Profile');
if (\false) {
class Twig_Profiler_Profile extends Profile
{
}
}
RuntimeLoaderInterface.php000064400000000324151160705120011645
0ustar00<?php
use Twig\RuntimeLoader\RuntimeLoaderInterface;
class_exists('Twig\RuntimeLoader\RuntimeLoaderInterface');
if (\false) {
class Twig_RuntimeLoaderInterface extends RuntimeLoaderInterface
{
}
}
Sandbox/SecurityError.php000064400000000254151160705120011473
0ustar00<?php
use Twig\Sandbox\SecurityError;
class_exists('Twig\Sandbox\SecurityError');
if (\false) {
class Twig_Sandbox_SecurityError extends SecurityError
{
}
}
Sandbox/SecurityNotAllowedFilterError.php000064400000000354151160705120014633
0ustar00<?php
use Twig\Sandbox\SecurityNotAllowedFilterError;
class_exists('Twig\Sandbox\SecurityNotAllowedFilterError');
if (\false) {
class Twig_Sandbox_SecurityNotAllowedFilterError extends
SecurityNotAllowedFilterError
{
}
}
Sandbox/SecurityNotAllowedFunctionError.php000064400000000364151160705120015174
0ustar00<?php
use Twig\Sandbox\SecurityNotAllowedFunctionError;
class_exists('Twig\Sandbox\SecurityNotAllowedFunctionError');
if (\false) {
class Twig_Sandbox_SecurityNotAllowedFunctionError extends
SecurityNotAllowedFunctionError
{
}
}
Sandbox/SecurityNotAllowedMethodError.php000064400000000354151160705120014626
0ustar00<?php
use Twig\Sandbox\SecurityNotAllowedMethodError;
class_exists('Twig\Sandbox\SecurityNotAllowedMethodError');
if (\false) {
class Twig_Sandbox_SecurityNotAllowedMethodError extends
SecurityNotAllowedMethodError
{
}
}
Sandbox/SecurityNotAllowedPropertyError.php000064400000000364151160705120015233
0ustar00<?php
use Twig\Sandbox\SecurityNotAllowedPropertyError;
class_exists('Twig\Sandbox\SecurityNotAllowedPropertyError');
if (\false) {
class Twig_Sandbox_SecurityNotAllowedPropertyError extends
SecurityNotAllowedPropertyError
{
}
}
Sandbox/SecurityNotAllowedTagError.php000064400000000340151160705120014114
0ustar00<?php
use Twig\Sandbox\SecurityNotAllowedTagError;
class_exists('Twig\Sandbox\SecurityNotAllowedTagError');
if (\false) {
class Twig_Sandbox_SecurityNotAllowedTagError extends
SecurityNotAllowedTagError
{
}
}
Sandbox/SecurityPolicy.php000064400000000260151160705120011636
0ustar00<?php
use Twig\Sandbox\SecurityPolicy;
class_exists('Twig\Sandbox\SecurityPolicy');
if (\false) {
class Twig_Sandbox_SecurityPolicy extends SecurityPolicy
{
}
}
Sandbox/SecurityPolicyInterface.php000064400000000324151160705120013460
0ustar00<?php
use Twig\Sandbox\SecurityPolicyInterface;
class_exists('Twig\Sandbox\SecurityPolicyInterface');
if (\false) {
class Twig_Sandbox_SecurityPolicyInterface extends
SecurityPolicyInterface
{
}
}
SimpleFilter.php000064400000000212151160705120007645 0ustar00<?php
use Twig\TwigFilter;
class_exists('Twig\TwigFilter');
if (\false) {
class Twig_SimpleFilter extends TwigFilter
{
}
}
SimpleFunction.php000064400000000222151160705130010207 0ustar00<?php
use Twig\TwigFunction;
class_exists('Twig\TwigFunction');
if (\false) {
class Twig_SimpleFunction extends TwigFunction
{
}
}
SimpleTest.php000064400000000202151160705130007337 0ustar00<?php
use Twig\TwigTest;
class_exists('Twig\TwigTest');
if (\false) {
class Twig_SimpleTest extends TwigTest
{
}
}
Source.php000064400000000170151160705130006512 0ustar00<?php
use Twig\Source;
class_exists('Twig\Source');
if (\false) {
class Twig_Source extends Source
{
}
}
SourceContextLoaderInterface.php000064400000000336151160705130013033
0ustar00<?php
use Twig\Loader\SourceContextLoaderInterface;
class_exists('Twig\Loader\SourceContextLoaderInterface');
if (\false) {
class Twig_SourceContextLoaderInterface extends
SourceContextLoaderInterface
{
}
}
Template.php000064400000000200151160705130007017 0ustar00<?php
use Twig\Template;
class_exists('Twig\Template');
if (\false) {
class Twig_Template extends Template
{
}
}
TemplateInterface.php000064400000002313151160705130010647 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\Environment;
/**
* Interface implemented by all compiled templates.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 3.0)
*/
interface Twig_TemplateInterface
{
const ANY_CALL = 'any';
const ARRAY_CALL = 'array';
const METHOD_CALL = 'method';
/**
* Renders the template with the given context and returns it as
string.
*
* @param array $context An array of parameters to pass to the template
*
* @return string The rendered template
*/
public function render(array $context);
/**
* Displays the template with the given context.
*
* @param array $context An array of parameters to pass to the template
* @param array $blocks An array of blocks to pass to the template
*/
public function display(array $context, array $blocks = []);
/**
* Returns the bound environment for this template.
*
* @return Environment
*/
public function getEnvironment();
}
TemplateWrapper.php000064400000000234151160705130010367 0ustar00<?php
use Twig\TemplateWrapper;
class_exists('Twig\TemplateWrapper');
if (\false) {
class Twig_TemplateWrapper extends TemplateWrapper
{
}
}
Test/Function.php000064400000001527151160705130007765 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
@trigger_error('The Twig_Test_Function class is deprecated since
version 1.12 and will be removed in 2.0. Use \Twig\TwigTest instead.',
E_USER_DEPRECATED);
/**
* Represents a function template test.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
class Twig_Test_Function extends Twig_Test
{
protected $function;
public function __construct($function, array $options = [])
{
$options['callable'] = $function;
parent::__construct($options);
$this->function = $function;
}
public function compile()
{
return $this->function;
}
}
Test/IntegrationTestCase.php000064400000000273151160705130012114
0ustar00<?php
use Twig\Test\IntegrationTestCase;
class_exists('Twig\Test\IntegrationTestCase');
if (\false) {
class Twig_Test_IntegrationTestCase extends IntegrationTestCase
{
}
}
Test/Method.php000064400000002052151160705130007412 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\Extension\ExtensionInterface;
@trigger_error('The Twig_Test_Method class is deprecated since version
1.12 and will be removed in 2.0. Use \Twig\TwigTest instead.',
E_USER_DEPRECATED);
/**
* Represents a method template test.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
class Twig_Test_Method extends Twig_Test
{
protected $extension;
protected $method;
public function __construct(ExtensionInterface $extension, $method,
array $options = [])
{
$options['callable'] = [$extension, $method];
parent::__construct($options);
$this->extension = $extension;
$this->method = $method;
}
public function compile()
{
return
sprintf('$this->env->getExtension(\'%s\')->%s',
\get_class($this->extension), $this->method);
}
}
Test/Node.php000064400000001446151160705130007065 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
@trigger_error('The Twig_Test_Node class is deprecated since version
1.12 and will be removed in 2.0.', E_USER_DEPRECATED);
/**
* Represents a template test as a Node.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
class Twig_Test_Node extends Twig_Test
{
protected $class;
public function __construct($class, array $options = [])
{
parent::__construct($options);
$this->class = $class;
}
public function getClass()
{
return $this->class;
}
public function compile()
{
}
}
Test/NodeTestCase.php000064400000000237151160705130010516 0ustar00<?php
use Twig\Test\NodeTestCase;
class_exists('Twig\Test\NodeTestCase');
if (\false) {
class Twig_Test_NodeTestCase extends NodeTestCase
{
}
}
Test.php000064400000001564151160705130006201 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
@trigger_error('The Twig_Test class is deprecated since version 1.12
and will be removed in 2.0. Use \Twig\TwigTest instead.',
E_USER_DEPRECATED);
/**
* Represents a template test.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
abstract class Twig_Test implements Twig_TestInterface,
Twig_TestCallableInterface
{
protected $options;
protected $arguments = [];
public function __construct(array $options = [])
{
$this->options = array_merge([
'callable' => null,
], $options);
}
public function getCallable()
{
return $this->options['callable'];
}
}
TestCallableInterface.php000064400000000656151160705130011443
0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
/**
* Represents a callable template test.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
interface Twig_TestCallableInterface
{
public function getCallable();
}
TestInterface.php000064400000000770151160705130010020 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
/**
* Represents a template test.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
interface Twig_TestInterface
{
/**
* Compiles a test.
*
* @return string The PHP code for the test
*/
public function compile();
}
Token.php000064400000000164151160705130006335 0ustar00<?php
use Twig\Token;
class_exists('Twig\Token');
if (\false) {
class Twig_Token extends Token
{
}
}
TokenParser/AutoEscape.php000064400000000315151160705130011541
0ustar00<?php
use Twig\TokenParser\AutoEscapeTokenParser;
class_exists('Twig\TokenParser\AutoEscapeTokenParser');
if (\false) {
class Twig_TokenParser_AutoEscape extends AutoEscapeTokenParser
{
}
}
TokenParser/Block.php000064400000000271151160705130010543 0ustar00<?php
use Twig\TokenParser\BlockTokenParser;
class_exists('Twig\TokenParser\BlockTokenParser');
if (\false) {
class Twig_TokenParser_Block extends BlockTokenParser
{
}
}
TokenParser/Deprecated.php000064400000000315151160705130011550
0ustar00<?php
use Twig\TokenParser\DeprecatedTokenParser;
class_exists('Twig\TokenParser\DeprecatedTokenParser');
if (\false) {
class Twig_TokenParser_Deprecated extends DeprecatedTokenParser
{
}
}
TokenParser/Do.php000064400000000255151160705130010055 0ustar00<?php
use Twig\TokenParser\DoTokenParser;
class_exists('Twig\TokenParser\DoTokenParser');
if (\false) {
class Twig_TokenParser_Do extends DoTokenParser
{
}
}
TokenParser/Embed.php000064400000000271151160705130010525 0ustar00<?php
use Twig\TokenParser\EmbedTokenParser;
class_exists('Twig\TokenParser\EmbedTokenParser');
if (\false) {
class Twig_TokenParser_Embed extends EmbedTokenParser
{
}
}
TokenParser/Extends.php000064400000000301151160705130011115
0ustar00<?php
use Twig\TokenParser\ExtendsTokenParser;
class_exists('Twig\TokenParser\ExtendsTokenParser');
if (\false) {
class Twig_TokenParser_Extends extends ExtendsTokenParser
{
}
}
TokenParser/Filter.php000064400000000275151160705130010742 0ustar00<?php
use Twig\TokenParser\FilterTokenParser;
class_exists('Twig\TokenParser\FilterTokenParser');
if (\false) {
class Twig_TokenParser_Filter extends FilterTokenParser
{
}
}
TokenParser/Flush.php000064400000000271151160705130010572 0ustar00<?php
use Twig\TokenParser\FlushTokenParser;
class_exists('Twig\TokenParser\FlushTokenParser');
if (\false) {
class Twig_TokenParser_Flush extends FlushTokenParser
{
}
}
TokenParser/For.php000064400000000261151160705130010236 0ustar00<?php
use Twig\TokenParser\ForTokenParser;
class_exists('Twig\TokenParser\ForTokenParser');
if (\false) {
class Twig_TokenParser_For extends ForTokenParser
{
}
}
TokenParser/From.php000064400000000265151160705130010417 0ustar00<?php
use Twig\TokenParser\FromTokenParser;
class_exists('Twig\TokenParser\FromTokenParser');
if (\false) {
class Twig_TokenParser_From extends FromTokenParser
{
}
}
TokenParser/If.php000064400000000255151160705130010051 0ustar00<?php
use Twig\TokenParser\IfTokenParser;
class_exists('Twig\TokenParser\IfTokenParser');
if (\false) {
class Twig_TokenParser_If extends IfTokenParser
{
}
}
TokenParser/Import.php000064400000000275151160705130010767 0ustar00<?php
use Twig\TokenParser\ImportTokenParser;
class_exists('Twig\TokenParser\ImportTokenParser');
if (\false) {
class Twig_TokenParser_Import extends ImportTokenParser
{
}
}
TokenParser/Include.php000064400000000301151160705130011066
0ustar00<?php
use Twig\TokenParser\IncludeTokenParser;
class_exists('Twig\TokenParser\IncludeTokenParser');
if (\false) {
class Twig_TokenParser_Include extends IncludeTokenParser
{
}
}
TokenParser/Macro.php000064400000000271151160705130010552 0ustar00<?php
use Twig\TokenParser\MacroTokenParser;
class_exists('Twig\TokenParser\MacroTokenParser');
if (\false) {
class Twig_TokenParser_Macro extends MacroTokenParser
{
}
}
TokenParser/Sandbox.php000064400000000301151160705130011101
0ustar00<?php
use Twig\TokenParser\SandboxTokenParser;
class_exists('Twig\TokenParser\SandboxTokenParser');
if (\false) {
class Twig_TokenParser_Sandbox extends SandboxTokenParser
{
}
}
TokenParser/Set.php000064400000000261151160705130010243 0ustar00<?php
use Twig\TokenParser\SetTokenParser;
class_exists('Twig\TokenParser\SetTokenParser');
if (\false) {
class Twig_TokenParser_Set extends SetTokenParser
{
}
}
TokenParser/Spaceless.php000064400000000311151160705130011426
0ustar00<?php
use Twig\TokenParser\SpacelessTokenParser;
class_exists('Twig\TokenParser\SpacelessTokenParser');
if (\false) {
class Twig_TokenParser_Spaceless extends SpacelessTokenParser
{
}
}
TokenParser/Use.php000064400000000261151160705130010244 0ustar00<?php
use Twig\TokenParser\UseTokenParser;
class_exists('Twig\TokenParser\UseTokenParser');
if (\false) {
class Twig_TokenParser_Use extends UseTokenParser
{
}
}
TokenParser/With.php000064400000000265151160705130010427 0ustar00<?php
use Twig\TokenParser\WithTokenParser;
class_exists('Twig\TokenParser\WithTokenParser');
if (\false) {
class Twig_TokenParser_With extends WithTokenParser
{
}
}
TokenParser.php000064400000000274151160705130007514 0ustar00<?php
use Twig\TokenParser\AbstractTokenParser;
class_exists('Twig\TokenParser\AbstractTokenParser');
if (\false) {
class Twig_TokenParser extends AbstractTokenParser
{
}
}
TokenParserBroker.php000064400000007000151160705130010653 0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
* (c) Arnaud Le Blanc
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\TokenParser\TokenParserInterface;
/**
* Default implementation of a token parser broker.
*
* @author Arnaud Le Blanc <arnaud.lb@gmail.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
class Twig_TokenParserBroker implements Twig_TokenParserBrokerInterface
{
protected $parser;
protected $parsers = [];
protected $brokers = [];
/**
* @param array|\Traversable $parsers A \Traversable of
Twig_TokenParserInterface instances
* @param array|\Traversable $brokers A \Traversable of
Twig_TokenParserBrokerInterface instances
* @param bool $triggerDeprecationError
*/
public function __construct($parsers = [], $brokers = [],
$triggerDeprecationError = true)
{
if ($triggerDeprecationError) {
@trigger_error('The '.__CLASS__.' class is
deprecated since version 1.12 and will be removed in 2.0.',
E_USER_DEPRECATED);
}
foreach ($parsers as $parser) {
if (!$parser instanceof TokenParserInterface) {
throw new \LogicException('$parsers must a an array of
Twig_TokenParserInterface.');
}
$this->parsers[$parser->getTag()] = $parser;
}
foreach ($brokers as $broker) {
if (!$broker instanceof Twig_TokenParserBrokerInterface) {
throw new \LogicException('$brokers must a an array of
Twig_TokenParserBrokerInterface.');
}
$this->brokers[] = $broker;
}
}
public function addTokenParser(TokenParserInterface $parser)
{
$this->parsers[$parser->getTag()] = $parser;
}
public function removeTokenParser(TokenParserInterface $parser)
{
$name = $parser->getTag();
if (isset($this->parsers[$name]) && $parser ===
$this->parsers[$name]) {
unset($this->parsers[$name]);
}
}
public function addTokenParserBroker(self $broker)
{
$this->brokers[] = $broker;
}
public function removeTokenParserBroker(self $broker)
{
if (false !== $pos = array_search($broker, $this->brokers)) {
unset($this->brokers[$pos]);
}
}
/**
* Gets a suitable TokenParser for a tag.
*
* First looks in parsers, then in brokers.
*
* @param string $tag A tag name
*
* @return TokenParserInterface|null A Twig_TokenParserInterface or
null if no suitable TokenParser was found
*/
public function getTokenParser($tag)
{
if (isset($this->parsers[$tag])) {
return $this->parsers[$tag];
}
$broker = end($this->brokers);
while (false !== $broker) {
$parser = $broker->getTokenParser($tag);
if (null !== $parser) {
return $parser;
}
$broker = prev($this->brokers);
}
}
public function getParsers()
{
return $this->parsers;
}
public function getParser()
{
return $this->parser;
}
public function setParser(Twig_ParserInterface $parser)
{
$this->parser = $parser;
foreach ($this->parsers as $tokenParser) {
$tokenParser->setParser($parser);
}
foreach ($this->brokers as $broker) {
$broker->setParser($parser);
}
}
}
TokenParserBrokerInterface.php000064400000002317151160705130012502
0ustar00<?php
/*
* This file is part of Twig.
*
* (c) Fabien Potencier
* (c) Arnaud Le Blanc
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use Twig\TokenParser\TokenParserInterface;
/**
* Interface implemented by token parser brokers.
*
* Token parser brokers allows to implement custom logic in the process of
resolving a token parser for a given tag name.
*
* @author Arnaud Le Blanc <arnaud.lb@gmail.com>
*
* @deprecated since 1.12 (to be removed in 2.0)
*/
interface Twig_TokenParserBrokerInterface
{
/**
* Gets a TokenParser suitable for a tag.
*
* @param string $tag A tag name
*
* @return TokenParserInterface|null A Twig_TokenParserInterface or
null if no suitable TokenParser was found
*/
public function getTokenParser($tag);
/**
* Calls Twig\TokenParser\TokenParserInterface::setParser on all
parsers the implementation knows of.
*/
public function setParser(Twig_ParserInterface $parser);
/**
* Gets the Twig_ParserInterface.
*
* @return Twig_ParserInterface|null A Twig_ParserInterface instance or
null
*/
public function getParser();
}
TokenParserInterface.php000064400000000310151160705130011324
0ustar00<?php
use Twig\TokenParser\TokenParserInterface;
class_exists('Twig\TokenParser\TokenParserInterface');
if (\false) {
class Twig_TokenParserInterface extends TokenParserInterface
{
}
}
TokenStream.php000064400000000214151160705130007505 0ustar00<?php
use Twig\TokenStream;
class_exists('Twig\TokenStream');
if (\false) {
class Twig_TokenStream extends TokenStream
{
}
}
Util/DeprecationCollector.php000064400000000277151160705130012303
0ustar00<?php
use Twig\Util\DeprecationCollector;
class_exists('Twig\Util\DeprecationCollector');
if (\false) {
class Twig_Util_DeprecationCollector extends DeprecationCollector
{
}
}
Util/TemplateDirIterator.php000064400000000273151160705130012117
0ustar00<?php
use Twig\Util\TemplateDirIterator;
class_exists('Twig\Util\TemplateDirIterator');
if (\false) {
class Twig_Util_TemplateDirIterator extends TemplateDirIterator
{
}
}