private static void processAnnotation(Annotation annotation, Map<String, Object> fieldsCollector)
{
// for each field in the annotation
for (Method field : annotation.annotationType().getMethods()) {
// if the field is annotated with the descriptor key
DescriptorKey descriptorKey = field.getAnnotation(DescriptorKey.class);
if (descriptorKey == null) {
continue;
}
// name is the name of the method
String name = descriptorKey.value();
// invoke method to get the value
Object value;
try {
value = field.invoke(annotation);