def getElementsByLocalName(childNodes, localName):
 elementsByLocalName = getChildElementsByLocalName(childNodes, localName)
 for childNode in childNodes:
  if (childNode.getNodeType() == 1):
   elementsByLocalName += childNode.getElementsByLocalName(localName)
 return elementsByLocalName

def getElementsByLocalName ( childNodes , localName ) : elementsByLocalName = getChildElementsByLocalName ( childNodes , localName ) for childNode in childNodes : if ( childNode . getNodeType ( ) == 1 ) : elementsByLocalName += childNode . getElementsByLocalName ( localName ) return elementsByLocalName
get the descendents which have the given local name .