mirror of
https://gitee.com/zhangsken/AndroidIDE.git
synced 2026-10-16 07:49:44 +08:00
refactor: fix typo in method name
This commit is contained in:
@@ -64,7 +64,7 @@ public class JavaCompilerProvider {
|
||||
// TODO This currently destroys all the compiler instances
|
||||
// We must have a method to destroy only the required instance in
|
||||
// JavaLanguageServer.handleFailure(LSPFailure)
|
||||
public synchronized void destory() {
|
||||
public synchronized void destroy() {
|
||||
for (final JavaCompilerService compiler : mCompilers.values()) {
|
||||
compiler.destroy();
|
||||
}
|
||||
|
||||
@@ -113,7 +113,7 @@ public class JavaLanguageServer implements ILanguageServer {
|
||||
|
||||
@Override
|
||||
public void shutdown() {
|
||||
JavaCompilerProvider.getInstance().destory();
|
||||
JavaCompilerProvider.getInstance().destroy();
|
||||
SourceFileManager.clearCache();
|
||||
CacheFSInfoSingleton.INSTANCE.clearCache();
|
||||
CachingJarFileSystemProvider.INSTANCE.clearCache();
|
||||
@@ -157,7 +157,7 @@ public class JavaLanguageServer implements ILanguageServer {
|
||||
CachingJarFileSystemProvider.INSTANCE.clearCachesForPaths(path -> path.endsWith("/R.jar"));
|
||||
|
||||
// Clear cached module-specific compilers
|
||||
JavaCompilerProvider.getInstance().destory();
|
||||
JavaCompilerProvider.getInstance().destroy();
|
||||
|
||||
// Cache classpath locations
|
||||
for (final Project subModule : project.getSubModules()) {
|
||||
@@ -260,7 +260,7 @@ public class JavaLanguageServer implements ILanguageServer {
|
||||
return true;
|
||||
}
|
||||
|
||||
JavaCompilerProvider.getInstance().destory();
|
||||
JavaCompilerProvider.getInstance().destroy();
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -60,7 +60,7 @@ class JavaCompilerProviderTest {
|
||||
assertThat(compilers).hasSize(5)
|
||||
|
||||
compilers.clear()
|
||||
JavaCompilerProvider.getInstance().destory()
|
||||
JavaCompilerProvider.getInstance().destroy()
|
||||
|
||||
assertThat(JavaCompilerProvider.get(appModule)).isNotEqualTo(appCompiler)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user