public class RangeValidator extends java.lang.Object implements Field.Validator
Constructor and Description |
---|
RangeValidator(java.lang.Class<? extends java.lang.Comparable> type,
java.lang.Comparable minValue,
java.lang.Comparable maxValue) |
RangeValidator(org.dom4j.Element element,
java.lang.String messagesPack) |
RangeValidator(java.lang.String message,
java.lang.String messagesPack,
java.lang.Class<? extends java.lang.Comparable> type,
java.lang.Comparable minValue,
java.lang.Comparable maxValue) |
Modifier and Type | Method and Description |
---|---|
java.lang.Comparable |
getMaxValue() |
java.lang.Comparable |
getMinValue() |
boolean |
isIgnoreCase() |
boolean |
isIncludeMaxValue() |
boolean |
isIncludeMinValue() |
void |
setIgnoreCase(boolean ignoreCase) |
void |
setIncludeMaxValue(boolean includeMaxValue) |
void |
setIncludeMinValue(boolean includeMinValue) |
void |
setMaxValue(java.lang.Comparable maxValue) |
void |
setMinValue(java.lang.Comparable minValue) |
void |
validate(java.lang.Object value) |
public RangeValidator(org.dom4j.Element element, java.lang.String messagesPack)
public RangeValidator(java.lang.String message, java.lang.String messagesPack, java.lang.Class<? extends java.lang.Comparable> type, java.lang.Comparable minValue, java.lang.Comparable maxValue)
public RangeValidator(java.lang.Class<? extends java.lang.Comparable> type, java.lang.Comparable minValue, java.lang.Comparable maxValue)
public void validate(java.lang.Object value) throws ValidationException
validate
in interface Field.Validator
value
- field value to validateValidationException
- this exception must be thrown by the validator if the value is not validpublic boolean isIncludeMinValue()
public void setIncludeMinValue(boolean includeMinValue)
public boolean isIncludeMaxValue()
public void setIncludeMaxValue(boolean includeMaxValue)
public boolean isIgnoreCase()
public void setIgnoreCase(boolean ignoreCase)
public java.lang.Comparable getMinValue()
public void setMinValue(java.lang.Comparable minValue)
public java.lang.Comparable getMaxValue()
public void setMaxValue(java.lang.Comparable maxValue)