Add a resource with its all children resources to the current
        resource.
342948
def add_from_child(self, resource, **kwargs):
        

        new_resource = self.add(
            resource.member_name, resource.collection_name, **kwargs)
        for child in resource.children:
            new_resource.add_from_child(child, **kwargs)
271355
public void addOrgUnitResource(String resourceName) {

        if ((m_throwable != null) || (m_orgUnitName == null)) {
            return;
        }
        if (m_orgUnitResources == null) {
            m_orgUnitResources = new HashMap<String, List<String>>();
        }
        List<String> resources = m_orgUnitResources.get(m_orgUnitName);
        if (resources == null) {
            resources = new ArrayList<String>();
            m_orgUnitResources.put(m_orgUnitName, resources);
        }
        resources.add(resourceName);
    }
526677
public void addChildren(List<? extends Tree> kids) {
		for (int i = 0; i < kids.size(); i++) {
			Tree t = kids.get(i);
			addChild(t);
		}
	}
1137725
def append(self, child):
        """"""
        if not (isinstance(child, CP2KSection) or isinstance(child, CP2KKeyword)):
            raise TypeError("The child must be a CP2KSection or a CP2KKeyword, got: %s." % child)
        l = self.__index.setdefault(child.name, [])
        l.append(child)
        self.__order.append(child)
249646
def add_children(self, children):
        

        self._children += [c for c in children if c not in self._children]
364137
def add_to(self, parent, name=None, index=None):
        """"""
        parent.add_child(self, name=name, index=index)
        return self
108817
def add_child(self, child):
        """"""
        assert isinstance(child, Term)
        self.children.append(child)
        child.parent = self
        assert not child.term_is("Datafile.Section")
557107
def set_children(self, value, defined):
        """"""
        self.children = value
        self.children_defined = defined
        return self
116354
public void add(List<T> resources)
    {
        for(T resource : resources)
        {
            if(resource.getId() != null)
                ids.put(resource.getId(), resource);
            if(resource instanceof NamedResource)
                addName((NamedResource)resource);
        }
    }
168492
def add(self, resource, replace=False):
        """"""
        uri = resource.uri
        if (uri in self and not replace):
            raise ResourceListDupeError(
                "Attempt to add resource already in resource_list")
        self[uri] = resource
421955
def add(self, resource):
        """"""
        if isinstance(resource, Resource):
            if isinstance(resource, Secret) and \
               resource.mount != 'cubbyhole':
                ensure_backend(resource,
                               SecretBackend,
                               self._mounts,
                               self.opt,
                               False)
            elif isinstance(resource, Mount):
                ensure_backend(resource, SecretBackend, self._mounts, self.opt)
            elif isinstance(resource, Auth):
                ensure_backend(resource, AuthBackend, self._auths, self.opt)
            elif isinstance(resource, AuditLog):
                ensure_backend(resource, LogBackend, self._logs, self.opt)

            self._resources.append(resource)
        else:
            msg = "Unknown resource %s being " \
                  "added to context" % resource.__class__
            raise aomi_excep.AomiError(msg)
59374
function () {
        // Iterate children_resources
        _.each(this.children_resources, (resource, resourceName) => {
          // Iterate object json data
          _.each(this._json, (object, key) => {
            // If children_resource and object different, next
            if (resourceName !== key) {
              return
            }

            if (object instanceof Array) {
              /*
             * Iterate array object to extend from
             * target Conekta resource and overwrite attribute
             */
              const childrenObjects = []
              _.each(object, (elem) => {
                const resourceInstance = _.extend({}, Conekta[resource])
                childrenObjects.push(
                  _.extend(resourceInstance, {
                    _json: elem,
                    _id: elem.id
                  })
                )
              })

              /* overwrite property */
              this[key] = childrenObjects
            } else if (object) {
              /* overwrite property */
              this[key] = _.extend(Conekta[resource], {
                _json: object,
                _id: object.id
              })
            }
          })
        })
      }
825829
protected function insertResources(array $resources)
    {
        foreach ($resources as $resource) {
            if (null === $resource->getParent()) {
                $this->addResource($resource);
            } else {
                $parent = $resource->getParent()->getResourceId();
                $this->addResource($resource, $parent);
            }
        }

        return $this;
    }
498577
def add(self, *args):
        
        self.children.extend(args)
        bump_child_depth(self, self._depth)
        return self.children
1370958
public void add(DepTreeNode child) {
		if (children == null) {
			children = new HashMap<String, DepTreeNode>();
		}
		children.put(child.getName(), child);
		child.setParent(this);
	}
730171
def add_child(self, child, name=None, index=None):
        """"""
        self.m1.add_child(child, name, index)
        if index is None:
            index = len(self.m2._children)
        self.children_for_m2.append((child, name, index))
408012
def new_children(self, **kwargs):
        """"""
        for k, v in kwargs.items():
            self.new_child(k, v)

        return self