PsiElement () { PsiPackage aPackage = JavaPsiFacade.getInstance(getProject()).findPackage(getText()); if (aPackage != null) { return aPackage; } return ClassUtil.findPsiClass(getManager(), getText(), null, true, getResolveScope()); }