Yaffs site version 1.1
[yaffs-website] / vendor / symfony / config / Tests / Fixtures / Builder / NodeBuilder.php
1 <?php
2
3 /*
4  * This file is part of the Symfony package.
5  *
6  * (c) Fabien Potencier <fabien@symfony.com>
7  *
8  * For the full copyright and license information, please view the LICENSE
9  * file that was distributed with this source code.
10  */
11
12 namespace Symfony\Component\Config\Tests\Definition\Builder;
13
14 use Symfony\Component\Config\Definition\Builder\NodeBuilder as BaseNodeBuilder;
15
16 class NodeBuilder extends BaseNodeBuilder
17 {
18     public function barNode($name)
19     {
20         return $this->node($name, 'bar');
21     }
22
23     protected function getNodeClass($type)
24     {
25         switch ($type) {
26             case 'variable':
27                 return __NAMESPACE__.'\\'.ucfirst($type).'NodeDefinition';
28             case 'bar':
29                 return __NAMESPACE__.'\\'.ucfirst($type).'NodeDefinition';
30             default:
31                 return parent::getNodeClass($type);
32         }
33     }
34 }