KT-11410: generate light classes from multifile class parts in binaries

if explicitly requested by fqName
This commit is contained in:
Dmitry Petrov
2016-03-24 17:20:25 +03:00
parent 4c4141ea49
commit 92ddbb271a
4 changed files with 27 additions and 1 deletions
@@ -92,6 +92,7 @@ public class JavaElementFinder extends PsiElementFinder implements KotlinFinderM
findClassesAndObjects(qualifiedName, scope, answer);
answer.addAll(lightClassGenerationSupport.getFacadeClasses(qualifiedName, scope));
answer.addAll(lightClassGenerationSupport.getMultifilePartClasses(qualifiedName, scope));
return sortByClasspath(answer, scope).toArray(new PsiClass[answer.size()]);
}
@@ -75,6 +75,9 @@ public abstract class LightClassGenerationSupport {
@NotNull
public abstract Collection<PsiClass> getFacadeClasses(@NotNull FqName facadeFqName, @NotNull GlobalSearchScope scope);
@NotNull
public abstract Collection<PsiClass> getMultifilePartClasses(@NotNull FqName partFqName, @NotNull GlobalSearchScope scope);
@NotNull
public abstract Collection<PsiClass> getFacadeClassesInPackage(@NotNull FqName packageFqName, @NotNull GlobalSearchScope scope);
@@ -86,5 +89,4 @@ public abstract class LightClassGenerationSupport {
@NotNull
public abstract LightClassConstructionContext getContextForFacade(@NotNull Collection<KtFile> files);
}