public class DoubleIntervalValidator extends AbstractNumberIntervalValidator<Double>
ContentValidator
validating the content by comparing one or more couples of double values.Constructor and Description |
---|
DoubleIntervalValidator() |
Modifier and Type | Method and Description |
---|---|
protected SimpleField<Double> |
getEmptyValue()
Get a value holder containing an empty value array.
|
protected SimpleField<Double> |
getValues(Form parentForm,
String fieldName)
Get the values of the field to validate from the form.
|
protected boolean |
isLessThan(Double n1,
Double n2)
Test if the first number is less than the second one.
|
addErrorEmpty, addIntervalError, configureMaxPath, configureMinPath, isSupportedType
_validateInterval, configure, service, validate, validate
getContentType, setContentType
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
public DoubleIntervalValidator()
protected SimpleField<Double> getValues(Form parentForm, String fieldName)
AbstractIntervalValidator
getValues
in class AbstractIntervalValidator<Double>
parentForm
- The form containing the user values.fieldName
- The field name.protected SimpleField<Double> getEmptyValue()
AbstractIntervalValidator
getEmptyValue
in class AbstractIntervalValidator<Double>
protected boolean isLessThan(Double n1, Double n2)
AbstractIntervalValidator
isLessThan
in class AbstractIntervalValidator<Double>
n1
- The first number to compare.n2
- The second number to compare.