无论我在 Eclipse 中做什么,都会出现错误。
启动时,Java 工具初始化时出现错误。当我想打开类型时出现错误。而且总是同样的错误。
例如,当打开一个类型时我得到:
An internal error occurred during: "Cache refresh".
2048
启动时的错误也打印错误代码为2048。
我正在使用最新版本的 Eclipse。
您知道如何解决这个问题吗?
编辑:这里是 Java 工具初始化时错误的堆栈跟踪:
java.lang.ArrayIndexOutOfBoundsException: 2048
at org.eclipse.jdt.internal.core.index.DiskIndex.readStreamChars(DiskIndex.java:870)
at org.eclipse.jdt.internal.core.index.DiskIndex.initialize(DiskIndex.java:370)
at org.eclipse.jdt.internal.core.index.Index.<init>(Index.java:96)
at org.eclipse.jdt.internal.core.search.indexing.IndexManager.getIndex(IndexManager.java:248)
at org.eclipse.jdt.internal.core.search.indexing.IndexManager.getIndexes(IndexManager.java:309)
at org.eclipse.jdt.internal.core.search.PatternSearchJob.getIndexes(PatternSearchJob.java:81)
at org.eclipse.jdt.internal.core.search.PatternSearchJob.ensureReadyToRun(PatternSearchJob.java:50)
at org.eclipse.jdt.internal.core.search.processing.JobManager.performConcurrentJob(JobManager.java:174)
at org.eclipse.jdt.internal.core.search.BasicSearchEngine.searchAllTypeNames(BasicSearchEngine.java:1122)
at org.eclipse.jdt.core.search.SearchEngine.searchAllTypeNames(SearchEngine.java:713)
at org.eclipse.jdt.internal.ui.dialogs.FilteredTypesSelectionDialog$ConsistencyRunnable.refreshSearchIndices(FilteredTypesSelectionDialog.java:653)
at org.eclipse.jdt.internal.ui.dialogs.FilteredTypesSelectionDialog$ConsistencyRunnable.run(FilteredTypesSelectionDialog.java:636)
at org.eclipse.jdt.internal.ui.dialogs.FilteredTypesSelectionDialog.reloadCache(FilteredTypesSelectionDialog.java:679)
at org.eclipse.ui.dialogs.FilteredItemsSelectionDialog$RefreshCacheJob.run(FilteredItemsSelectionDialog.java:1502)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
答案1
我现在扫描了磁盘,这似乎是解决问题的方法。