Package gov.nasa.pds.tools.dict.type
Class DoubleChecker
- java.lang.Object
-
- gov.nasa.pds.tools.dict.type.LengthChecker
-
- gov.nasa.pds.tools.dict.type.DoubleChecker
-
- All Implemented Interfaces:
NumericTypeChecker,TypeChecker
public class DoubleChecker extends LengthChecker implements NumericTypeChecker
- Version:
- $Revision$
- Author:
- pramirez, jagander
-
-
Constructor Summary
Constructors Constructor Description DoubleChecker()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Objectcast(String value, AttributeStatement attribute)Tries to cast the value to the appropriate type and return the valuevoidcheckMaxValue(Number value, ElementDefinition def, AttributeStatement attribute)voidcheckMinValue(Number value, ElementDefinition def, AttributeStatement attribute)-
Methods inherited from class gov.nasa.pds.tools.dict.type.LengthChecker
checkMaxLength, checkMinLength
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface gov.nasa.pds.tools.dict.type.TypeChecker
checkMaxLength, checkMinLength
-
-
-
-
Method Detail
-
cast
public Object cast(String value, AttributeStatement attribute) throws InvalidTypeException
Description copied from interface:TypeCheckerTries to cast the value to the appropriate type and return the value- Specified by:
castin interfaceTypeChecker- Parameters:
value- which must be cast- Returns:
- value after it has been cast
- Throws:
InvalidTypeException- thrown when value can not be cast
-
checkMinValue
public void checkMinValue(Number value, ElementDefinition def, AttributeStatement attribute) throws OutOfRangeException
- Specified by:
checkMinValuein interfaceNumericTypeChecker- Throws:
OutOfRangeException
-
checkMaxValue
public void checkMaxValue(Number value, ElementDefinition def, AttributeStatement attribute) throws OutOfRangeException
- Specified by:
checkMaxValuein interfaceNumericTypeChecker- Throws:
OutOfRangeException
-
-