01: /*
02: * JFox - The most lightweight Java EE Application Server!
03: * more details please visit http://www.huihoo.org/jfox or http://www.jfox.org.cn.
04: *
05: * JFox is licenced and re-distributable under GNU LGPL.
06: */
07: package org.jfox.mvc.validate;
08:
09: import java.lang.annotation.Retention;
10: import java.lang.annotation.RetentionPolicy;
11: import java.lang.annotation.Target;
12: import java.lang.annotation.ElementType;
13:
14: /**
15: * @author <a href="mailto:jfox.young@gmail.com">Yang Yong</a>
16: */
17: @Retention(RetentionPolicy.RUNTIME)
18: @Target(ElementType.FIELD)
19: public @interface IntegerValidation {
20: /**
21: * default integer validator class
22: */
23: Class<? extends Validator> validatorClass() default IntegerValidator.class;
24:
25: /**
26: * min value
27: */
28: int minValue() default Integer.MIN_VALUE;
29:
30: /**
31: * max value
32: */
33: int maxValue() default Integer.MAX_VALUE;
34:
35: /**
36: * nullable
37: */
38: boolean nullable() default false;
39: }
|