V
- is the generic type of the value to validate
.public class ValidatorRange<V extends Comparable<V>> extends AbstractValueValidator<V>
ValueValidator
that validates that a given value is within
a specific Range
.Constructor and Description |
---|
ValidatorRange(Range<V> range)
The constructor.
|
ValidatorRange(V min,
V max)
The constructor.
|
Modifier and Type | Method and Description |
---|---|
protected NlsMessage |
validateNotNull(V value)
This method performs the validation in case
value is NOT null . |
validate, validateNull
createBundle, getCode, isDynamic, isMandatory, validate
private final Range<V extends Comparable<V>> range
validateNotNull(Comparable)
public ValidatorRange(Range<V> range)
range
- is the Range
the value has to be within.protected NlsMessage validateNotNull(V value)
value
is NOT null
. This method contains the
actual custom logic for the validation. It is therefore designed in a way that makes it most simple to implement
custom validators. NlsMessage
instead.validateNotNull
in class AbstractValueValidator<V extends Comparable<V>>
value
- is the value to validate.failure message
or null
if the the given
value
is valid.Copyright © 2001–2014 mmm-Team. All rights reserved.