Add a person as a child in a family.

@param person the person
@param family the family
@return the Child object
185471
public Child addChildToFamily(final Family family, final Person person) {
        if (family == null || person == null) {
            return new Child();
        }
        final FamC famC = new FamC(person, "FAMC",
                new ObjectId(family.getString()));
        final Child child = new Child(family, "Child",
                new ObjectId(person.getString()));
        family.insert(child);
        person.insert(famC);
        return child;
    }
112946
public void addChild(Config child)
  {
    Params.notNull(child, "Child");
    child.parent = this;
    children.add(child);
  }
113090
public function addChild(ServerRequestInterface $request, Tree $tree): ResponseInterface
    {
        $xref   = $request->get('xref', '');
        $gender = $request->get('gender', 'U');

        $family = Family::getInstance($xref, $tree);

        Auth::checkFamilyAccess($family, true);

        $title = $family->fullName() . ' - ' . I18N::translate('Add a child');

        return $this->viewResponse('edit/new-individual', [
            'tree'       => $tree,
            'title'      => $title,
            'nextaction' => 'add_child_to_family_action',
            'individual' => null,
            'family'     => $family,
            'name_fact'  => null,
            'famtag'     => 'CHIL',
            'gender'     => $gender,
        ]);
    }
1133435
public void add(T parent, T child) {
        final Set<T> children = depTree.computeIfAbsent(parent, p -> new LinkedHashSet<>());
        if (!child.equals(parent)) {
            children.add(child);
        }
    }
1090150
public function createFamilyQueryBuilder(FamilyInterface $family, $alias = 'e')
    {
        return new SingleFamilyQueryBuilder($family, $this->createQueryBuilder($alias), $alias);
    }
1220682
public Person getMother() {
        if (!isSet()) {
            return new Person();
        }
        final Person mother = (Person) find(getToString());
        if (mother == null) {
            return new Person();
        } else {
            return mother;
        }
    }
724981
public function addUser(ChildUser $user)
    {
        if ($this->collUsers === null) {
            $this->initUsers();
        }

        if (!$this->getUsers()->contains($user)) {
            // only add it if the **same** object is not already associated
            $this->collUsers->push($user);
            $this->doAddUser($user);
        }

        return $this;
    }
610800
public void add(ColumnFamily columnFamily)
    {
        assert columnFamily != null;
        ColumnFamily prev = modifications.put(columnFamily.id(), columnFamily);
        if (prev != null)
            // developer error
            throw new IllegalArgumentException("ColumnFamily " + columnFamily + " already has modifications in this mutation: " + prev);
    }
883676
private void analyzeFamily(final Family family) {
        Person prevChild = null;
        final FamilyNavigator navigator = new FamilyNavigator(family);
        for (final Person child : navigator.getChildren()) {
            prevChild = analyzeChild(child, prevChild);
        }
    }
230091
protected void addLogical(Widget child) {
		// Detach new child.
		child.removeFromParent();

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

		// Adopt.
		adopt(child);
	}
759440
public void addFirstChild( AstNode child ) {
        assert child != null;
        this.children.addFirst(child);
        child.removeFromParent();
        child.parent = this;
    }
228729
public Person getSpouse(final GedObject person) {
        final List<Person> spouses = visitor.getSpouses();
        if (person != null && !spouses.contains(person)) {
            return new Person();
        }
        for (final Person spouse : spouses) {
            if (!spouse.equals(person)) {
                return spouse;
            }
        }
        return new Person();
    }
286503
public function addPersonImage(ChildPersonImage $l)
    {
        if ($this->collPersonImages === null) {
            $this->initPersonImages();
            $this->collPersonImagesPartial = true;
        }

        if (!in_array($l, $this->collPersonImages->getArrayCopy(), true)) { // only add it if the **same** object is not already associated
            $this->doAddPersonImage($l);
        }

        return $this;
    }
526677
public void addChildren(List<? extends Tree> kids) {
		for (int i = 0; i < kids.size(); i++) {
			Tree t = kids.get(i);
			addChild(t);
		}
	}
388179
def add_individual(self, individual_object):
        
        ind_id = individual_object.individual_id
        self.logger.info("Adding individual {0}".format(ind_id))
        family_id = individual_object.family
        if family_id != self.family_id:
            raise PedigreeError(self.family, individual_object.individual_id,
                "Family id of individual is not the same as family id for "\
                                    "Family object!")
        else:
            self.individuals[ind_id] = individual_object
            self.logger.debug("Individual {0} added to family {1}".format(
                ind_id, family_id
            ))
        return
1040738
public boolean addChildObject(GVRSceneObject child) {
        if (child.mParent == this) {
            return false;
        }
        if (child.mParent != null) {
            throw new UnsupportedOperationException("GVRSceneObject cannot have multiple parents");
        }
        mChildren.add(child);
        child.mParent = this;
        NativeSceneObject.addChildObject(getNative(), child.getNative());
        child.onNewParentObject(this);
        return true;
    }
1317126
private void addChild(Session session, GroupImpl parent, GroupImpl child, boolean broadcast) throws Exception
   {
      Node parentNode = utils.getGroupNode(session, parent);
      Node groupNode =
         parentNode.addNode(child.getGroupName(), JCROrganizationServiceImpl.JOS_HIERARCHY_GROUP_NODETYPE);

      String parentId = parent == null ? null : parent.getId();

      child.setParentId(parentId);
      child.setInternalId(groupNode.getUUID());

      if (broadcast)
      {
         preSave(child, true);
      }

      writeGroup(child, groupNode);
      session.save();

      putInCache(child);

      if (broadcast)
      {
         postSave(child, true);
      }
   }