void (PyClass aClass, HashSet<PyClass> visited) { visited.add(aClass); for (PyClass clazz : aClass.getSuperClasses(null)) { getSubclasses(clazz).add(aClass); if (!visited.contains(clazz)) { buildSubClassesMapImpl(clazz, visited); } } }