use of meghanada.reflect.asm.InheritanceInfo in project meghanada-server by mopemope.
the class MemberCacheLoader method loadFromReflector.
private List<MemberDescriptor> loadFromReflector(String fqcn) {
final String initName = ClassNameUtils.getSimpleName(fqcn);
final ASMReflector asmReflector = ASMReflector.getInstance();
Map<String, ClassIndex> index = CachedASMReflector.getInstance().getGlobalClassIndex();
final InheritanceInfo info = asmReflector.getReflectInfo(index, fqcn);
final List<MemberDescriptor> result = asmReflector.reflectAll(info);
return result.stream().filter(md -> {
if (md.matchType(CandidateUnit.MemberType.CONSTRUCTOR)) {
final String name = ClassNameUtils.getSimpleName(md.getName());
return name.equals(initName);
}
return true;
}).collect(Collectors.toList());
}
Aggregations