FileDocCategorySizeDatePackage
PrecisionDecimalDV.javaAPI DocApache Xerces 3.0.114499Fri Sep 14 20:33:56 BST 2007org.apache.xerces.impl.dv.xs

PrecisionDecimalDV

public class PrecisionDecimalDV extends TypeValidator
Validator for datatype (W3C Schema 1.1)
xerces.experimental
author
Ankit Pasricha, IBM
version
$Id: PrecisionDecimalDV.java 446745 2006-09-15 21:43:58Z mrglavas $

Fields Summary
Constructors Summary
Methods Summary
public intcompare(java.lang.Object value1, java.lang.Object value2)

        return ((XPrecisionDecimal)value1).compareTo((XPrecisionDecimal)value2);
    
public java.lang.ObjectgetActualValue(java.lang.String content, org.apache.xerces.impl.dv.ValidationContext context)

        try {
            return new XPrecisionDecimal(content);
        } catch (NumberFormatException nfe) {
            throw new InvalidDatatypeValueException("cvc-datatype-valid.1.2.1", new Object[]{content, "precisionDecimal"});
        }
    
public shortgetAllowedFacets()

        return ( XSSimpleTypeDecl.FACET_PATTERN | XSSimpleTypeDecl.FACET_WHITESPACE | XSSimpleTypeDecl.FACET_ENUMERATION |XSSimpleTypeDecl.FACET_MAXINCLUSIVE |XSSimpleTypeDecl.FACET_MININCLUSIVE | XSSimpleTypeDecl.FACET_MAXEXCLUSIVE  | XSSimpleTypeDecl.FACET_MINEXCLUSIVE | XSSimpleTypeDecl.FACET_TOTALDIGITS | XSSimpleTypeDecl.FACET_FRACTIONDIGITS);
    
public intgetFractionDigits(java.lang.Object value)

        return ((XPrecisionDecimal)value).fracDigits;
    
public intgetTotalDigits(java.lang.Object value)

        return ((XPrecisionDecimal)value).totalDigits;
    
public booleanisIdentical(java.lang.Object value1, java.lang.Object value2)

        if(!(value2 instanceof XPrecisionDecimal) || !(value1 instanceof XPrecisionDecimal))
            return false;
        return ((XPrecisionDecimal)value1).isIdentical((XPrecisionDecimal)value2);