*/
private static @CheckForNull
IJavaElement getJavaElement(BugInstance bug, IJavaProject project) throws JavaModelException {
SourceLineAnnotation primarySourceLineAnnotation = bug.getPrimarySourceLineAnnotation();
PackageMemberAnnotation packageAnnotation = null;
String packageName = null;
String qualifiedClassName = null;
if (primarySourceLineAnnotation == null) {
packageAnnotation = bug.getPrimaryClass();
if (packageAnnotation != null) {
packageName = packageAnnotation.getPackageName();
qualifiedClassName = packageAnnotation.getClassName();
}
} else {
packageName = primarySourceLineAnnotation.getPackageName();
qualifiedClassName = primarySourceLineAnnotation.getClassName();
}