public boolean isEntity() { return isAnnotationPresent(Reference.class);// Reference not Yet // Supported // return propertyDescriptor != null // && propertyDescriptor.getPropertyType().isAnnotationPresent( // DynamoDBTable.class); // return false; }
public static List<String> getReferencedAttributeNames(Class<?> clazz) { List<String> referenceFields = new ArrayList<String>(); for(Field eachField : clazz.getDeclaredFields()) { if(eachField.getAnnotation(Reference.class) != null) { referenceFields.add(eachField.getName()); } } return referenceFields; }
public static boolean isReference(Field field) { return field.getAnnotation(Reference.class) != null; }