org.exolab.castor.xml.validators

Class DoubleValidator

public class DoubleValidator extends PatternValidator implements TypeValidator

The Double Validation class. This class handles validation for the double type.

Version: $Revision: 5951 $ $Date: 2003-03-03 02:57:21 -0700 (Mon, 03 Mar 2003) $

Author: Arnaud Blandin

Constructor Summary
DoubleValidator()
Creates a new DoubleValidator with no restrictions
Method Summary
voidsetFixed(double fixed)
Sets the fixed value the double to validate must be equal to.
voidsetMaxExclusive(double maxValue)
Sets the maximum value that decimals validated with this validator must be less than
voidsetMaxInclusive(double maxValue)
Sets the maximum value that decimals validated with this validator are allowed to be
voidsetMinExclusive(double minValue)
Sets the minimum value that decimals validated with this validator must be greater than
voidsetMinInclusive(double minValue)
Sets the minimum value that decimals validated with this validator are allowed to be
voidvalidate(double d, ValidationContext context)
voidvalidate(Object object)
Validates the given Object
voidvalidate(Object object, ValidationContext context)
Validates the given Object

Constructor Detail

DoubleValidator

public DoubleValidator()
Creates a new DoubleValidator with no restrictions

Method Detail

setFixed

public void setFixed(double fixed)
Sets the fixed value the double to validate must be equal to.

Parameters: fixed the fixed value

setMaxExclusive

public void setMaxExclusive(double maxValue)
Sets the maximum value that decimals validated with this validator must be less than

Parameters: maxValue the maximum value an doublevalidated with this validator must be less than

setMaxInclusive

public void setMaxInclusive(double maxValue)
Sets the maximum value that decimals validated with this validator are allowed to be

Parameters: maxValue the maximum value an doublevalidated with this validator may be

setMinExclusive

public void setMinExclusive(double minValue)
Sets the minimum value that decimals validated with this validator must be greater than

Parameters: minValue the minimum value an doublevalidated with this validator must be greater than

setMinInclusive

public void setMinInclusive(double minValue)
Sets the minimum value that decimals validated with this validator are allowed to be

Parameters: minValue the minimum value an doublevalidated with this validator may be

validate

public void validate(double d, ValidationContext context)

validate

public void validate(Object object)
Validates the given Object

Parameters: object the Object to validate

validate

public void validate(Object object, ValidationContext context)
Validates the given Object

Parameters: object the Object to validate context the ValidationContext

Intalio Inc. (C) 1999-2006. All rights reserved http://www.intalio.com