Method to remove and return all children of current node

        :return: list of children
771896
def PopAllChildren(self):
        '''
        
        '''
        indexes = self.GetChildrenIndexes()
        children = []
        for c in indexes:
            child = self.PopChild(c)
            children.append(child)
        return children
490402
def _fetchAllChildren(self):
        
        childItems = []
        logger.debug("{!r} _fetchAllChildren {!r}".format(self, self.fileName))

        if self.hasChildren():
            for key, value in sorted(self._dictionary.items()):
                # TODO: pass the attributes to the children? (probably not)
                childItem = _createFromObject(value, str(key), self.fileName)
                childItem._iconColor = self.iconColor
                childItems.append(childItem)

        return childItems
1144788
def remove_child(self, child):
        
        try:
            self.children.remove(child)
        except ValueError as e:
            raise TreeError("child not found")
        else:
            child.up = None
            return child
845106
def empty(self):
        """"""
        for k in list(self.children.keys()):
            self.remove_child(self.children[k])
343260
def clear_children(self):
        
        if (self.get_children_metadata().is_read_only() or
                self.get_children_metadata().is_required()):
            raise errors.NoAccess()
        self._my_map['childIds'] = self._children_default
949204
def get_children(self, request):
        
        node = decode_node(request.data)
        return _get_children(node, request.depth)
1061177
def children(self) :
        ""
        if not self.isdir() : raise Exception("FSQuery tried to return the children of a node which is not a directory : %s" % self.abs)
        return [FSNode(self.abs + "/" + x,self.root,self.depth+1) for x in os.listdir(self.abs)]
454334
def _get_all_children(self,):
        
        res = ''
        if self.child_nodes:
            for c in self.child_nodes:
                res += ' child = ' + str(c) + '\n'
                if c.child_nodes:
                    for grandchild in c.child_nodes:
                        res += '   child = ' + str(grandchild) + '\n'
        else:
            res += ' child = None\n'
        return res
148053
def get_children(self):
        """"""
        if hasattr(self, '_cached_children'):
            children = self._toplevel().objects.filter(
                pk__in=[n.pk for n in self._cached_children]
            )
            children._result_cache = self._cached_children
            return children
        else:
            return self.get_descendants(include_self=False, depth=1)
36154
public void removeChildren() {
        for (int i = children.size() - 1; i >= 0; i--) {
            removeChild(children.get(i), true);
        }
    }
396308
def filter_children(self, ctype: ContentType = None) -> List[SchemaNode]:
        
        if ctype is None:
            ctype = self.content_type()
        return [c for c in self.children if
                not isinstance(c, (RpcActionNode, NotificationNode)) and
                c.content_type().value & ctype.value != 0]
1023876
def remove_children(self, reset_parent=True):
        
        if reset_parent:
            for child in self.children:
                child.parent = None
        self.__children = []
565262
def removeChild(self, child: Node) -> Node:
        
        if self.connected:
            self._remove_child_web(child)
        return self._remove_child(child)
1179395
def get_all_children(self):
        """"""
        all_children = set()
        for parent in self.children:
            all_children.add(parent.item_id)
            all_children |= parent.get_all_children()
        return all_children
311674
def cleanup(self):
        
        self.lock.acquire()
        logger.debug('Acquired lock in cleanup for ' + str(self))
        self.children = [child for child in self.children if child.is_alive()]
        self.lock.release()
1239793
def children(self):
        
        children = []
        child_nodes = getattr(self.parsed_response, 'Children')
        for child in getattr(child_nodes, 'BrowseNode', []):
            children.append(AmazonBrowseNode(child))
        return children
965311
def _prune(current, keys):
    
    pruned_current = {k: current[k] for k in keys if k in current}
    pruned_children = list(
        filter(
            None, [_prune(c, keys) for c in current.get("IORegistryEntryChildren", [])]
        )
    )
    keep_current = any(k in current for k in keys) or pruned_children
    if keep_current:
        if pruned_children:
            pruned_current["IORegistryEntryChildren"] = pruned_children
        return pruned_current
    else:
        return {}