* * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Component\Config\Tests\Fixtures\Configuration; use Symfony\Component\Config\Definition\Builder\TreeBuilder; use Symfony\Component\Config\Definition\ConfigurationInterface; class ExampleConfiguration implements ConfigurationInterface { public function getConfigTreeBuilder() { $treeBuilder = new TreeBuilder(); $rootNode = $treeBuilder->root('acme_root'); $rootNode ->fixXmlConfig('parameter') ->fixXmlConfig('connection') ->fixXmlConfig('cms_page') ->children() ->booleanNode('boolean')->defaultTrue()->end() ->scalarNode('scalar_empty')->end() ->scalarNode('scalar_null')->defaultNull()->end() ->scalarNode('scalar_true')->defaultTrue()->end() ->scalarNode('scalar_false')->defaultFalse()->end() ->scalarNode('scalar_default')->defaultValue('default')->end() ->scalarNode('scalar_array_empty')->defaultValue(array())->end() ->scalarNode('scalar_array_defaults')->defaultValue(array('elem1', 'elem2'))->end() ->scalarNode('scalar_required')->isRequired()->end() ->scalarNode('scalar_deprecated')->setDeprecated()->end() ->scalarNode('scalar_deprecated_with_message')->setDeprecated('Deprecation custom message for "%node%" at "%path%"')->end() ->scalarNode('node_with_a_looong_name')->end() ->enumNode('enum_with_default')->values(array('this', 'that'))->defaultValue('this')->end() ->enumNode('enum')->values(array('this', 'that'))->end() ->arrayNode('array') ->info('some info') ->canBeUnset() ->children() ->scalarNode('child1')->end() ->scalarNode('child2')->end() ->scalarNode('child3') ->info( "this is a long\n". "multi-line info text\n". 'which should be indented' ) ->example('example setting') ->end() ->end() ->end() ->arrayNode('scalar_prototyped') ->prototype('scalar')->end() ->end() ->arrayNode('parameters') ->useAttributeAsKey('name') ->prototype('scalar')->info('Parameter name')->end() ->end() ->arrayNode('connections') ->prototype('array') ->children() ->scalarNode('user')->end() ->scalarNode('pass')->end() ->end() ->end() ->end() ->arrayNode('cms_pages') ->useAttributeAsKey('page') ->prototype('array') ->useAttributeAsKey('locale') ->prototype('array') ->children() ->scalarNode('title')->isRequired()->end() ->scalarNode('path')->isRequired()->end() ->end() ->end() ->end() ->end() ->arrayNode('pipou') ->useAttributeAsKey('name') ->prototype('array') ->prototype('array') ->children() ->scalarNode('didou') ->end() ->end() ->end() ->end() ->end() ->end() ; return $treeBuilder; } } __halt_compiler();----SIGNATURE:----kw7WivPJGdBNUXPHJGIGgHpBQ1dg1u9b5JhXScQi1ULQMtdCCHFDX0m/xclU7D6/dcHq3bI2kt4oYTXVjFUevzjX+KiewvA5cWf9j08tcS0Avs6iF7GDltU/MhNpbthjgBrvPb6SoJFKIAU1g3JZ9CxbEE1nOWnDyFggyKMj49ZLi4HCxkmj4O/yru1xVu0sBPsPFN7DA3mvE7Sr6TjvLOZr2FfsF5+ao8LOZm8hxHUEvOUlNRlMbWN9KoFY8tfrotXZnPaKcRWB589xtODsD+yOssAKCQkzockGNPuhoFRNge13lQpHt0er2p1zg1YPYfNeZHGoLkuj/zSrTb27g4Qmx4XaTyZbx7faoMshIjA5bpX+wBEZx48ArMFLjH+vdFeSLjTkAiJZPG0VPKYXC7dnPZfmBPl3IVgYuranwgRSIuB+kY6wt1am+G8Md9pPl0P0tFav1q8NNzypiSWyVATAD5tpFC0DT/pELHYfoFV0RKwCazkl6/yOWKS+KruoPbrFZBZ23Juevz4lyLVczDHFXuoUuwnrPzYU0Jirs5x9HS+MZaXZYIrZm+YcwWDjkN2owNfuj5b93+egP1rqL0NeOqo+uDICw7N8xkTkcR2e4F6DrNG/EnXcZIuSe7Y9Z2ZWbO5HOpjtSz6E9kZMC09TyTyJqkGSZ6lJxUD9u/s=----ATTACHMENT:----NjczOTQxNTU4MTM1ODIxNyA2MjIyNDc2MjYxOTU1NTIgNDk4OTY1OTkxMjU3ODgwNw==