adds a new child to element

@param Form_ElementModel $child new child to get added
326169
public function addChild(Form_ElementModel $child)
	{
		if(!$this->allowChildren)
		{
			throw new Exception(__CLASS__." doesn't support children");
		}
		$this->children[] = $child;
	}
1121481
public function addChild(Content $child)
    {
        $this->pages[$child->id] = $child;

        // Group by category
        if (!isset($this->categories[$child->category])) {
            $this->categories[$child->category] = [];
        }

        // Add post to category
        $this->categories[$child->category][] = $child;
    }
340106
def add_child(self, child):
        
        child.set_model(self._model)
        if self._model:
            row = len(self.childItems)
            parentindex = self._model.index_of_item(self)
            self._model.insertRow(row, child, parentindex)
        else:
            self.childItems.append(child)
901868
public function addChild(LeafRole $child)
    {
        $this->children->add($child);
        $child->setParent($this);

        return $this;
    }
433090
public function addChild(NodeContract $child)
    {
        $this->children[] = $child;

        $child->setParent($this);
        $child->setIndex(count($this->children) - 1);

        return $this;
    }
549061
public void addChild(Item child) {
        if (children == null) {
            children = new ArrayList<>();
        }

        children.add(child);
    }
693557
protected function takeChildFromDOM($child)
    {
        $absoluteNodeName = $child->namespaceURI . ':' . $child->localName;

        switch ($absoluteNodeName) {
            case $this->lookupNamespace('apps') . ':' . 'emailList';
                $emailList = new Zend_Gdata_Gapps_Extension_EmailList();
                $emailList->transferFromDOM($child);
                $this->_emailList = $emailList;
                break;
            case $this->lookupNamespace('gd') . ':' . 'feedLink';
                $feedLink = new Zend_Gdata_Extension_FeedLink();
                $feedLink->transferFromDOM($child);
                $this->_feedLink[] = $feedLink;
                break;
            default:
                parent::takeChildFromDOM($child);
                break;
        }
    }
954326
public function addChild(SwatObject $child)
    {
        if ($child instanceof SwatCellRenderer) {
            $this->addRenderer($child);
        } else {
            throw new SwatInvalidClassException(
                'Only SwatCellRender objects may be nested within ' .
                    get_class($this) .
                    ' objects.',
                0,
                $child
            );
        }
    }
1209130
public function addChild(\Librinfo\VarietiesBundle\Entity\Variety $child)
    {
        $this->children[] = $child;

        return $this;
    }
73518
public function addChild(SwatObject $child)
    {
        if ($child instanceof SwatDetailsViewField) {
            $this->appendField($child);
        } else {
            $class_name = get_class($child);

            throw new SwatInvalidClassException(
                "Unable to add '{$class_name}' object to SwatDetailsView. " .
                    'Only SwatDetailsViewField objects may be nested within ' .
                    'SwatDetailsView objects.',
                0,
                $child
            );
        }
    }
541265
protected function takeChildFromDOM($child)
    {
        $absoluteNodeName = $child->namespaceURI . ':' . $child->localName;

        switch ($absoluteNodeName) {
            case $this->lookupNamespace('gml') . ':' . 'pos';
                $pos = new Zend_Gdata_Geo_Extension_GmlPos();
                $pos->transferFromDOM($child);
                $this->_pos = $pos;
                break;
        }
    }
216125
public function addChild(AssociatedMetadata $child)
    {
        $this->children[$child->getMetadata()->getEntityClass()] = $child;

        return $this;
    }
1067786
protected void add(Widget child, Element container) {

        // Detach new child.
        child.removeFromParent();

        // Logical attach.
        getChildren().add(child);

        // Physical attach.
        DOM.appendChild(container, child.getElement());

        // Adopt.
        adopt(child);
    }
318703
protected function takeChildFromDOM($child)
    {
        $absoluteNodeName = $child->namespaceURI . ':' . $child->localName;

        switch ($absoluteNodeName) {
            case $this->lookupNamespace('gml') . ':' . 'Point';
                $point = new Zend_Gdata_Geo_Extension_GmlPoint();
                $point->transferFromDOM($child);
                $this->_point = $point;
                break;
        }
    }
1064328
public function insertBefore(AbstractNode $child, int $id): bool
	{
		return $this->addChild($child, $id);
	}
71667
public Node<T> addChild(Node<T> child) {
        if (children == null) {
            children = new ArrayList<Node<T>>();
        }
        child.parent = this;
        children.add(child);

        return child;
    }
1063726
public function add($child, $other = null){
		if($other){
			throw new \Exception('Inserting before not supported');
		}else{
			$this->children[] = $child;
		}
		return $child;
	}