Details
-
Bug
-
Resolution: Unresolved
-
Blocker
-
None
-
None
-
None
-
Oracle JDK 6 and OpenJDK 7
Description
THIS AFFECTS VERSION 0.8.1 WHICH IS NOT IN JIRA!!!
I have an enum which contains these fields public static final String FLAG_KEY and private final Type type. The AnnotationProcessor extracts not only the enum constants but also these fields.
The output is:
/MyEnum.java:[9,8] Key [FLAG_KEY] present in enum type
.
The problem is this method:
@Override public List<String> extractKeysInEnum() { List<String> keyList = new ArrayList<String>(); for (VariableElement ve : ElementFilter.fieldsIn(typeElementForEnum.getEnclosedElements())) { keyList.add(ve.getSimpleName().toString()); } return keyList; }
getEnclosedElements returns these elements and breaks the build.