Create annotation
//create annotation @Target({ElementType.METHOD}) @Retention(RetentionPolicy.RUNTIME) public @interface TransientMakeCheck {}
//check if method contains specific Annotation
private static boolean needMakeCheck(PropertyDescriptor propertyDescriptor) {
Method readMethod = propertyDescriptor.getReadMethod();
if (readMethod == null) {
return false;
} else {
return readMethod.getAnnotation(TransientMakeCheck.class) == null;
}
}