Verzeichnisstruktur phpBB-3.2.0


Veröffentlicht
06.01.2017

So funktioniert es


Auf das letzte Element klicken. Dies geht jeweils ein Schritt zurück

Auf das Icon klicken, dies öffnet das Verzeichnis. Nochmal klicken schließt das Verzeichnis.
Auf den Verzeichnisnamen klicken, dies zeigt nur das Verzeichnis mit Inhalt an

(Beispiel Datei-Icons)

Auf das Icon klicken um den Quellcode anzuzeigen

Test.php

Zuletzt modifiziert: 09.10.2024, 12:59 - Dateigröße: 1.14 KiB


01  <?php
02   
03  /*
04   * This file is part of Twig.
05   *
06   * (c) 2010 Fabien Potencier
07   *
08   * For the full copyright and license information, please view the LICENSE
09   * file that was distributed with this source code.
10   */
11  class Twig_Node_Expression_Test extends Twig_Node_Expression_Call
12  {
13      public function __construct(Twig_NodeInterface $node, $name, Twig_NodeInterface $arguments = null, $lineno)
14      {
15          parent::__construct(array('node' => $node, 'arguments' => $arguments), array('name' => $name), $lineno);
16      }
17   
18      public function compile(Twig_Compiler $compiler)
19      {
20          $name = $this->getAttribute('name');
21          $test = $compiler->getEnvironment()->getTest($name);
22   
23          $this->setAttribute('name', $name);
24          $this->setAttribute('type', 'test');
25          $this->setAttribute('thing', $test);
26          if ($test instanceof Twig_TestCallableInterface || $test instanceof Twig_SimpleTest) {
27              $this->setAttribute('callable', $test->getCallable());
28          }
29          if ($test instanceof Twig_SimpleTest) {
30              $this->setAttribute('is_variadic', $test->isVariadic());
31          }
32   
33          $this->compileCallable($compiler);
34      }
35  }
36