com.google.gwt.validation.client
Class RangeValidator

java.lang.Object
  extended by com.google.gwt.validation.client.RangeValidator
All Implemented Interfaces:
IConstraint<Range>

public class RangeValidator
extends java.lang.Object
implements IConstraint<Range>

Implements the @Range annotation.

Author:
chris

Constructor Summary
RangeValidator()
           
 
Method Summary
 void initialize(java.util.Map<java.lang.String,java.lang.String> propertyMap)
          Initialize the constraint validator, this is a "hack" for GWT initialization
 void initialize(Range constraintAnnotation)
          Initialize the constraint validator.
 boolean isValid(java.lang.Object value)
          Evaluates the constraint against a value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RangeValidator

public RangeValidator()
Method Detail

initialize

public void initialize(Range constraintAnnotation)
Description copied from interface: IConstraint
Initialize the constraint validator.

Specified by:
initialize in interface IConstraint<Range>
Parameters:
constraintAnnotation - The constraint declaration

initialize

public void initialize(java.util.Map<java.lang.String,java.lang.String> propertyMap)
Description copied from interface: IConstraint
Initialize the constraint validator, this is a "hack" for GWT initialization

Specified by:
initialize in interface IConstraint<Range>

isValid

public boolean isValid(java.lang.Object value)
Description copied from interface: IConstraint
Evaluates the constraint against a value. This method must be thread safe.

Specified by:
isValid in interface IConstraint<Range>
Parameters:
value - The object to validate
Returns:
false if the value is not valid, true otherwise