use of org.eclipse.ceylon.compiler.java.codegen.CharacterLiteralAnnotationTerm in project ceylon by eclipse.
the class AnnotationLoader method readCharacterValuesAnnotation.
private LiteralAnnotationTerm readCharacterValuesAnnotation(AnnotationMirror valueAnnotation, boolean singleValue) {
if (singleValue) {
Integer value = getAnnotationIntegerValues(valueAnnotation, "value").get(0);
CharacterLiteralAnnotationTerm term = new CharacterLiteralAnnotationTerm(value);
return term;
} else {
CollectionLiteralAnnotationTerm result = new CollectionLiteralAnnotationTerm(CharacterLiteralAnnotationTerm.FACTORY);
for (Integer value : getAnnotationIntegerValues(valueAnnotation, "value")) {
result.addElement(new CharacterLiteralAnnotationTerm(value));
}
return result;
}
}
Aggregations