public function append(NodeDefinition $node)
    {
        if ($node instanceof ParentNodeDefinitionInterface) {
            $builder = clone $this;
            $builder->setParent(null);
            $node->setBuilder($builder);
        }

        if (null !== $this->parent) {
            $this->parent->append($node);
            // Make this builder the node parent to allow for a fluid interface
            $node->setParent($this);
        }

        return $this;
    }
public function append(NodeDefinition $node)
    {
        if ($node instanceof ParentNodeDefinitionInterface) {
            $builder = clone $this;
            $builder->setParent(null);
            $node->setBuilder($builder);
        }

        if (null !== $this->parent) {
            $this->parent->append($node);
            // Make this builder the node parent to allow for a fluid interface
            $node->setParent($this);
        }

        return $this;
    }
public function append ( NodeDefinition $ node ) { if ( $ node instanceof ParentNodeDefinitionInterface ) { $ builder = clone $ this ; $ builder -> setParent ( null ) ; $ node -> setBuilder ( $ builder ) ; } if ( null !== $ this -> parent ) { $ this -> parent -> append ( $ node ) ; // Make this builder the node parent to allow for a fluid interface $ node -> setParent ( $ this ) ; } return $ this ; }
Appends a node definition.

Usage:

$node = new ArrayNodeDefinition('name')
->children()
->scalarNode('foo')->end()
->scalarNode('baz')->end()
->append($this->getBarNodeDefinition())
->end()
;

@return $this
Appends a node definition .