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