setDefinition($id, new DefinitionDecorator('knp_gaufrette.adapter.doctrine_dbal')) ->addArgument(new Reference($config['doctrine_dbal_id'])) ->addArgument($config['table']); if (isset($config['columns'])) { $definition->addArgument($config['columns']); } } /** * Returns the key for the factory configuration * * @return string */ function getKey() { return 'doctrine_dbal'; } /** * Adds configuration nodes for the factory * * @param NodeDefinition $builder */ function addConfiguration(NodeDefinition $builder) { $builder ->children() ->scalarNode('doctrine_dbal_id')->isRequired()->cannotBeEmpty()->end() ->scalarNode('table')->isRequired()->cannotBeEmpty()->end() ->arrayNode('columns') ->children() ->scalarNode('key')->end() ->scalarNode('content')->end() ->scalarNode('mtime')->end() ->scalarNode('checksum')->end() ->end() ->end() ->end() ; } }