新增bean参数检查和list中bean参数检查注解
This commit is contained in:
parent
a78907a2bb
commit
5c0aa99035
@ -0,0 +1,16 @@
|
||||
package ink.wgink.annotation;
|
||||
|
||||
import java.lang.annotation.*;
|
||||
|
||||
/**
|
||||
* @ClassName: CheckObjectAnnotation
|
||||
* @Description: 检查对象注解,标记的对象可递归检查属性
|
||||
* @Author: wanggeng
|
||||
* @Date: 2021/8/19 2:14 下午
|
||||
* @Version: 1.0
|
||||
*/
|
||||
@Documented
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Target({ElementType.FIELD})
|
||||
public @interface CheckBeanAnnotation {
|
||||
}
|
@ -14,5 +14,9 @@ public @interface CheckBooleanAnnotation {
|
||||
|
||||
String name();
|
||||
|
||||
String value() default "";
|
||||
|
||||
String description() default "";
|
||||
|
||||
String[] types() default {};
|
||||
}
|
||||
|
@ -19,6 +19,10 @@ public @interface CheckEmptyAnnotation {
|
||||
|
||||
String name();
|
||||
|
||||
String value() default "";
|
||||
|
||||
String description() default "";
|
||||
|
||||
String[] types() default {};
|
||||
|
||||
String verifyType() default "";
|
||||
|
@ -19,4 +19,8 @@ public @interface CheckListAnnotation {
|
||||
|
||||
String name();
|
||||
|
||||
String value() default "";
|
||||
|
||||
String description() default "";
|
||||
|
||||
}
|
||||
|
@ -0,0 +1,16 @@
|
||||
package ink.wgink.annotation;
|
||||
|
||||
import java.lang.annotation.*;
|
||||
|
||||
/**
|
||||
* @ClassName: CheckListObjectAnnotation
|
||||
* @Description: 检查列表对象注解,标记的列表可递检查属性
|
||||
* @Author: wanggeng
|
||||
* @Date: 2021/8/19 2:15 下午
|
||||
* @Version: 1.0
|
||||
*/
|
||||
@Documented
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Target({ElementType.FIELD})
|
||||
public @interface CheckListBeanAnnotation {
|
||||
}
|
@ -19,5 +19,9 @@ public @interface CheckNullAnnotation {
|
||||
|
||||
String name();
|
||||
|
||||
String value() default "";
|
||||
|
||||
String description() default "";
|
||||
|
||||
String[] types() default {};
|
||||
}
|
||||
|
@ -19,6 +19,10 @@ public @interface CheckNumberAnnotation {
|
||||
|
||||
String name();
|
||||
|
||||
String value() default "";
|
||||
|
||||
String description() default "";
|
||||
|
||||
String[] types() default {};
|
||||
|
||||
double max() default Integer.MAX_VALUE;
|
||||
|
Loading…
Reference in New Issue
Block a user