update
This commit is contained in:
@@ -244,9 +244,13 @@ public class CodebaseContext {
|
||||
}
|
||||
|
||||
// Recursively index nested types
|
||||
for (Object type : td.getTypes()) {
|
||||
if (type instanceof TypeDeclaration nestedTd) {
|
||||
for (Object decl : td.bodyDeclarations()) {
|
||||
if (decl instanceof TypeDeclaration nestedTd) {
|
||||
indexType(nestedTd, fqn, javaFile);
|
||||
} else if (decl instanceof EnumDeclaration nestedEd) {
|
||||
indexEnum(nestedEd, fqn, javaFile);
|
||||
} else if (decl instanceof org.eclipse.jdt.core.dom.RecordDeclaration nestedRd) {
|
||||
indexRecord(nestedRd, fqn, javaFile);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -269,10 +273,12 @@ public class CodebaseContext {
|
||||
}
|
||||
|
||||
// Recursively index nested types
|
||||
for (Object type : rd.bodyDeclarations()) {
|
||||
if (type instanceof TypeDeclaration nestedTd) {
|
||||
for (Object decl : rd.bodyDeclarations()) {
|
||||
if (decl instanceof TypeDeclaration nestedTd) {
|
||||
indexType(nestedTd, fqn, javaFile);
|
||||
} else if (type instanceof org.eclipse.jdt.core.dom.RecordDeclaration nestedRd) {
|
||||
} else if (decl instanceof EnumDeclaration nestedEd) {
|
||||
indexEnum(nestedEd, fqn, javaFile);
|
||||
} else if (decl instanceof org.eclipse.jdt.core.dom.RecordDeclaration nestedRd) {
|
||||
indexRecord(nestedRd, fqn, javaFile);
|
||||
}
|
||||
}
|
||||
@@ -331,6 +337,17 @@ public class CodebaseContext {
|
||||
if (!simpleNameToFqn.containsKey(simpleName)) {
|
||||
simpleNameToFqn.put(simpleName, fqn);
|
||||
}
|
||||
|
||||
// Recursively index nested types inside enum body
|
||||
for (Object decl : ed.bodyDeclarations()) {
|
||||
if (decl instanceof TypeDeclaration nestedTd) {
|
||||
indexType(nestedTd, fqn, javaFile);
|
||||
} else if (decl instanceof EnumDeclaration nestedEd) {
|
||||
indexEnum(nestedEd, fqn, javaFile);
|
||||
} else if (decl instanceof org.eclipse.jdt.core.dom.RecordDeclaration nestedRd) {
|
||||
indexRecord(nestedRd, fqn, javaFile);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public Map<String, List<String>> getEnumValuesMap() {
|
||||
|
||||
Reference in New Issue
Block a user