Lines 3620-3632
Link Here
|
3620 |
ICompilationUnit unit = JavaModelManager.createCompilationUnitFrom((IFile)resource, null); |
3620 |
ICompilationUnit unit = JavaModelManager.createCompilationUnitFrom((IFile)resource, null); |
3621 |
if (unit != null) { |
3621 |
if (unit != null) { |
3622 |
String typeString = new String(typeName); |
3622 |
String typeString = new String(typeName); |
3623 |
String packageString = new String(packageName); |
3623 |
IType type = unit.getType(typeString); |
|
|
3624 |
// String packageString = new String(packageName); |
3625 |
// use package fragment name instead of parameter as it may be invalid... |
3626 |
// see bug https://bugs.eclipse.org/bugs/show_bug.cgi?id=186781 |
3627 |
String packageString = type.getPackageFragment().getElementName(); |
3624 |
HashMap packageTypes = (HashMap) allTypes.get(packageString); |
3628 |
HashMap packageTypes = (HashMap) allTypes.get(packageString); |
3625 |
if (packageTypes == null) { |
3629 |
if (packageTypes == null) { |
3626 |
packageTypes = new HashMap(3); |
3630 |
packageTypes = new HashMap(3); |
3627 |
allTypes.put(packageString, packageTypes); |
3631 |
allTypes.put(packageString, packageTypes); |
3628 |
} |
3632 |
} |
3629 |
packageTypes.put(typeString, unit.getType(typeString)); |
3633 |
packageTypes.put(typeString, type); |
3630 |
} |
3634 |
} |
3631 |
if (VERBOSE) { |
3635 |
if (VERBOSE) { |
3632 |
Util.verbose(" - indexing cache:"); //$NON-NLS-1$ |
3636 |
Util.verbose(" - indexing cache:"); //$NON-NLS-1$ |