'Collect every leaf sharing the same parent'

def collectLeaves(self, parentid):

    cl = []
    for e in self.__edges:
        if (e['parent'] == parentid):
            cl.append(e['id'])
    return cl
