for (JavaSourceTokenType tokenType : POSSIBLE_CLASS_DECLARATION_TYPES) {
final String tokenName = tokenType.getName();
List<Element> innerClassElementList =
context.selectNodes("/" + CLASS_TOP_LEVEL_SCOPE.getName() + "/" + tokenName);
for (Element innerClassElement : innerClassElementList) {
ClassDeclaration innerClass = new ClassDeclarationJdom(innerClassElement, DeclarationType.valueOf(tokenName), this);
innerClassDeclarationByNameMap.put(innerClass.getName(), innerClass);
}
}
}
return innerClassDeclarationByNameMap;
}