Verzeichnisstruktur phpBB-3.3.15


Veröffentlicht
28.08.2024

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

BooleanNodeDefinition.php

Zuletzt modifiziert: 02.04.2025, 15:03 - Dateigröße: 1.24 KiB


01  <?php
02   
03  /*
04   * This file is part of the Symfony package.
05   *
06   * (c) Fabien Potencier <fabien@symfony.com>
07   *
08   * For the full copyright and license information, please view the LICENSE
09   * file that was distributed with this source code.
10   */
11   
12  namespace Symfony\Component\Config\Definition\Builder;
13   
14  use Symfony\Component\Config\Definition\BooleanNode;
15  use Symfony\Component\Config\Definition\Exception\InvalidDefinitionException;
16   
17  /**
18   * This class provides a fluent interface for defining a node.
19   *
20   * @author Johannes M. Schmitt <schmittjoh@gmail.com>
21   */
22  class BooleanNodeDefinition extends ScalarNodeDefinition
23  {
24      /**
25       * {@inheritdoc}
26       */
27      public function __construct($name, NodeParentInterface $parent = null)
28      {
29          parent::__construct($name, $parent);
30   
31          $this->nullEquivalent = true;
32      }
33   
34      /**
35       * Instantiate a Node.
36       *
37       * @return BooleanNode The node
38       */
39      protected function instantiateNode()
40      {
41          return new BooleanNode($this->name, $this->parent);
42      }
43   
44      /**
45       * {@inheritdoc}
46       *
47       * @throws InvalidDefinitionException
48       */
49      public function cannotBeEmpty()
50      {
51          throw new InvalidDefinitionException('->cannotBeEmpty() is not applicable to BooleanNodeDefinition.');
52      }
53  }
54