Bug 72388 No types available after opening a closed project
hi, I am using: Version: 3.1.0 Build id: 200408170800 I had a few java projects that were closed before the last shutdown of hte eclipse platform. When I restarted the platform, i used the context menu to open one of the projects. I waited till i saw that the progress monitor showing that it had started building the classes. At this point, I hit Ctrl+Shift+T to get the "open type" dialog - but instead, I got an error dialog whote title was "Type Selection" saying that "No types available". At this stage, keeping the project open, if I shutdown and restart the eclipse platform, Ctrl+Shift+T works as expected. But I should not need to restart eclipse. Could this be rectified?
org.eclipse.jdt.ui.tests/ui/org/eclipse/jdt/ui/tests/core/AllTypesCacheTest.java
int nFlushes= AllTypesCache.getNumberOfCacheFlushes();
		IPackageFragment pack= fSourceFolder.getPackageFragment("");
		ICompilationUnit newCU= pack.getCompilationUnit("A.java");
		IType type= newCU.createType("public class A {\n}\n", null, true, null);
		assertTrue("cache not flushed after adding type", nFlushes != AllTypesCache.getNumberOfCacheFlushes());		
		res1.clear();
		AllTypesCache.getTypes(workspaceScope, IJavaSearchConstants.TYPE, null, res1);
		assertNotNull("A not found", findTypeRef(res1, "A"));
		assertTrue("543 types in workspace expected, is " + res1.size(), res1.size() == 543);
		
		
		
		nFlushes= AllTypesCache.getNumberOfCacheFlushes();
		type.createField("public int fCount;", null, true, null);
		assertTrue("cache was flushed", nFlushes == AllTypesCache.getNumberOfCacheFlushes());
		res1.clear();
		AllTypesCache.getTypes(workspaceScope, IJavaSearchConstants.TYPE, null, res1);		
		assertTrue("still 543 types in workspace expected, is " + res1.size(), res1.size() == 543);
		
		
		nFlushes= AllTypesCache.getNumberOfCacheFlushes();
		type.createType("public class AInner {}", null, true, null);
		res1.clear();
		AllTypesCache.getTypes(workspaceScope, IJavaSearchConstants.TYPE, null, res1);		
		assertTrue("cache not flushed after inner type creation", nFlushes != AllTypesCache.getNumberOfCacheFlushes());
		assertNotNull("AInner not found", findTypeRef(res1, "A.AInner"));
		assertTrue("still 544 types in workspace expected, is " + res1.size(), res1.size() == 544);
	}