@Documented @Retention(value=RUNTIME) @Target(value={METHOD,FIELD,ANNOTATION_TYPE}) @EachConstraint(validateAs=org.hibernate.validator.constraints.Mod11Check.class) @Constraint(validatedBy=CommonEachValidator.class) public @interface EachMod11Check
Mod11Check,
CommonEachValidator| Modifier and Type | Optional Element and Description |
|---|---|
int |
checkDigitIndex |
int |
endIndex |
Class<?>[] |
groups |
boolean |
ignoreNonDigitCharacters |
String |
message |
Class<? extends javax.validation.Payload>[] |
payload |
org.hibernate.validator.constraints.Mod11Check.ProcessingDirection |
processingDirection |
int |
startIndex |
int |
threshold |
char |
treatCheck10As |
char |
treatCheck11As |
public abstract String message
public abstract Class<?>[] groups
public abstract Class<? extends javax.validation.Payload>[] payload
public abstract int threshold
public abstract int startIndex
public abstract int endIndex
public abstract int checkDigitIndex
checkDigitIndex > 0 && (checkDigitIndex < startIndex || checkDigitIndex >= endIndex.public abstract boolean ignoreNonDigitCharacters
true) or result in a
validation error (false).public abstract char treatCheck10As
char that represents the check digit when the Mod11
checksum equals 10. If not specified 'X' is assumed.public abstract char treatCheck11As
char that represents the check digit when the Mod11
checksum equals 11. If not specified '0' is assumed.public abstract org.hibernate.validator.constraints.Mod11Check.ProcessingDirection processingDirection
RIGHT_TO_LEFT if the Mod11 checksum must be done from the rightmost to the leftmost digit.
e.g. Code 12345-?:
RIGHT_TO_LEFT the sum (5*2 + 4*3 + 3*4 + 2*5 + 1*6) with check digit 5LEFT_TO_RIGHT the sum (1*2 + 2*3 + 3*4 + 4*5 + 5*6) with check digit 7RIGHT_TO_LEFT is assumed, it is the default Mod11 behavior.Copyright © 2013–2014. All rights reserved.