def getChildCount(elem):
    count = 0
    child = elem.firstChild
    while child:
        if child.nodeType == 1:
            count += 1
        child = child.nextSibling
    return count
Calculate the number of children the given element has.  This loops
dataset/ETHPy150Open anandology/pyjamas/library/gwt/DOM.py/getChildCount