boolean isIntf = TypeDeclaration.kind(typeDecl.modifiers) == TypeDeclaration.INTERFACE_DECL;
boolean isAnnotation = TypeDeclaration.kind(typeDecl.modifiers) == TypeDeclaration.ANNOTATION_TYPE_DECL;
JRealClassType resultType;
if (isAnnotation) {
resultType = new JAnnotationType(typeOracle, pkg, enclosingType,
isLocalType, className, isIntf);
} else if (maybeGeneric(typeDecl, enclosingType)) {
// Go through and create declarations for each of the type parameters on
// the generic class or method
JTypeParameter[] jtypeParameters = declareTypeParameters(typeDecl.typeParameters);