Direct instantiations of VirtualFileKotlinClass are replaced by access to caching service
This commit is contained in:
+14
@@ -16,11 +16,25 @@
|
||||
|
||||
package org.jetbrains.jet.lang.resolve.kotlin;
|
||||
|
||||
import com.intellij.openapi.components.ServiceManager;
|
||||
import com.intellij.openapi.project.Project;
|
||||
import com.intellij.openapi.vfs.VirtualFile;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
import org.jetbrains.jet.lang.resolve.name.FqName;
|
||||
|
||||
public interface KotlinClassFinder {
|
||||
|
||||
class SERVICE {
|
||||
@NotNull
|
||||
public static KotlinClassFinder getInstance(@NotNull Project project) {
|
||||
return ServiceManager.getService(project, KotlinClassFinder.class);
|
||||
}
|
||||
}
|
||||
|
||||
@Nullable
|
||||
KotlinJvmBinaryClass findKotlinClass(@NotNull FqName fqName);
|
||||
|
||||
@NotNull
|
||||
KotlinJvmBinaryClass createKotlinClass(@NotNull VirtualFile virtualFile);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user