Skip to content

Instantly share code, notes, and snippets.

Created Oct 4, 2016
What would you like to do?
import static java.lang.annotation.ElementType.TYPE_USE;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
import java.lang.annotation.Documented;
import java.lang.annotation.Retention;
import java.lang.annotation.Target;
import javax.validation.Constraint;
import javax.validation.OverridesAttribute;
import javax.validation.Payload;
import javax.validation.constraints.Digits;
@Target({ TYPE_USE })
@Constraint(validatedBy = {})
@Digits(integer = 0, fraction = 0)
public @interface DigitsTypeUse {
@OverridesAttribute(constraint = Digits.class, name = "integer")
int integer();
@OverridesAttribute(constraint = Digits.class, name = "fraction")
int fraction();
String message() default "{javax.validation.constraints.Digits.message}";
Class<?>[] groups() default {};
Class<? extends Payload>[] payload() default {};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment