|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.miginfocom.property.RangeValidator<T>
public final class RangeValidator<T>
| Constructor Summary | |
|---|---|
RangeValidator(java.lang.Comparable<T> min,
java.lang.Comparable<T> max,
Result.Type resultType)
|
|
| Method Summary | ||
|---|---|---|
|
validate(Result<T> previousResult,
PropertyI<T> p,
T value,
PropertyEvent.Type type,
java.lang.Integer index)
Validates the potential setting of a new value for a property. |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public RangeValidator(java.lang.Comparable<T> min,
java.lang.Comparable<T> max,
Result.Type resultType)
| Method Detail |
|---|
public <T> Result<T> validate(Result<T> previousResult,
PropertyI<T> p,
T value,
PropertyEvent.Type type,
java.lang.Integer index)
Validator
validate in interface Validator<T>previousResult - The previus result from the validator before this one. If no validator exist before this one
Result.ok() will be provided. If the validation is ok this value should be returned. Never null.p - The property that is going to recieve value.value - The value to be set. Can be null. Should never be changed.type - The type of value to set.index - If the property is a CollectionProperty type that maintain element indexes
this index should reflect the index of the value that was, for instance, removed.
null!
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||