public abstract class ModCheckBase extends Object
| Constructor and Description |
|---|
ModCheckBase() |
| Modifier and Type | Method and Description |
|---|---|
protected int |
extractDigit(char value)
Returns the numeric
int value of a char |
protected void |
initialize(int startIndex,
int endIndex,
int checkDigitIndex,
boolean ignoreNonDigitCharacters) |
abstract boolean |
isCheckDigitValid(List<Integer> digits,
char checkDigit) |
boolean |
isValid(CharSequence value,
ConstraintValidatorContext context) |
public boolean isValid(CharSequence value, ConstraintValidatorContext context)
protected void initialize(int startIndex,
int endIndex,
int checkDigitIndex,
boolean ignoreNonDigitCharacters)
protected int extractDigit(char value)
throws NumberFormatException
int value of a charvalue - the input char to be parsedint value represented by the character.NumberFormatException - in case character is not a digitCopyright © 2018 JBoss by Red Hat. All rights reserved.