for (name, member) in getmembers(ET, isclass): # name is the value of ET and member is the value of isclass function which we want to look in the xml directors if not name.startswith('_'): print(name)