/** * Determine whether this type is supported when using XSD 1.0 * * @return true if this type is permitted in XSD 1.0 */ public boolean isAllowedInXSD10() { return getFingerprint() != StandardNames.XS_DATE_TIME_STAMP; }
/** * The fingerprint can be used as a hashcode */ public int hashCode() { return getFingerprint(); }
/** * Two types are equal if they have the same fingerprint. * Note: it is normally safe to use ==, because we always use the static constants, one instance * for each built in atomic type. However, after serialization and deserialization a different instance * can appear. */ public boolean equals(Object obj) { return obj instanceof BuiltInAtomicType && getFingerprint() == ((BuiltInAtomicType) obj).getFingerprint(); }
/** * Get the required type. Always StandardNames.XS_DOUBLE or StandardNames.XS_FLOAT * @return the fingerprint of the name of the required type */ public int getRequiredType() { return requiredType.getFingerprint(); }
/** * Two types are equal if they have the same fingerprint. * Note: it is normally safe to use ==, because we always use the static constants, one instance * for each built in atomic type. However, after serialization and deserialization a different instance * can appear. */ public boolean equals(Object obj) { return obj instanceof BuiltInAtomicType && getFingerprint() == ((BuiltInAtomicType) obj).getFingerprint(); }
/** * Two types are equal if they have the same fingerprint. * Note: it is normally safe to use ==, because we always use the static constants, one instance * for each built in atomic type. However, after serialization and deserialization a different instance * can appear. */ public boolean equals(Object obj) { return obj instanceof BuiltInAtomicType && getFingerprint() == ((BuiltInAtomicType)obj).getFingerprint(); }
/** * The fingerprint can be used as a hashcode */ public int hashCode() { return getFingerprint(); }
/** * Two types are equal if they have the same fingerprint. * Note: it is normally safe to use ==, because we always use the static constants, one instance * for each built in atomic type. However, after serialization and deserialization a different instance * can appear. */ public boolean equals(Object obj) { return obj instanceof BuiltInAtomicType && getFingerprint() == ((BuiltInAtomicType)obj).getFingerprint(); }
/** * The fingerprint can be used as a hashcode */ public int hashCode() { return getFingerprint(); }
/** * The fingerprint can be used as a hashcode */ public int hashCode() { return getFingerprint(); }
/** * Determine whether this type is supported when using XSD 1.0 * * @return true if this type is permitted in XSD 1.0 */ public boolean isAllowedInXSD10() { return getFingerprint() != StandardNames.XS_DATE_TIME_STAMP; }
/** * Test whether this is the same type as another type. They are considered to be the same type * if they are derived from the same type definition in the original XML representation (which * can happen when there are multiple includes of the same file) */ public boolean isSameType(SchemaType other) { return other.getFingerprint() == getFingerprint(); }
/** * Determine whether this type is supported in a basic XSLT processor * * @return true if this type is permitted in a basic XSLT processor */ public boolean isAllowedInBasicXSLT() { return (isPrimitiveType() && getFingerprint() != StandardNames.XS_NOTATION); }
/** * Test whether this is the same type as another type. They are considered to be the same type * if they are derived from the same type definition in the original XML representation (which * can happen when there are multiple includes of the same file) */ public boolean isSameType(SchemaType other) { return other.getFingerprint() == getFingerprint(); }
/** * Returns the built-in base type this type is derived from. * * @return the first built-in type found when searching up the type hierarchy */ public SchemaType getBuiltInBaseType() { BuiltInAtomicType base = this; while ((base != null) && (base.getFingerprint() > 1023)) { base = (BuiltInAtomicType)base.getBaseType(); } return base; }
/** * Test whether this is the same type as another type. They are considered to be the same type * if they are derived from the same type definition in the original XML representation (which * can happen when there are multiple includes of the same file) */ public boolean isSameType(SchemaType other) { return other.getFingerprint() == getFingerprint(); }
/** * Returns the built-in base type this type is derived from. * * @return the first built-in type found when searching up the type hierarchy */ public SchemaType getBuiltInBaseType() { BuiltInAtomicType base = this; while ((base != null) && (base.getFingerprint() > 1023)) { base = (BuiltInAtomicType)base.getBaseType(); } return base; }
/** * Get a comparison key for an object. This must satisfy the rule that if two objects are equal, * then their comparison keys are equal, and vice versa. There is no requirement that the * comparison keys should reflect the ordering of the underlying objects. */ public ComparisonKey getComparisonKey(AtomicValue a) { return new ComparisonKey(a.getPrimitiveType().getFingerprint(), a); } }
/** * Get a comparison key for an object. This must satisfy the rule that if two objects are equal, * then their comparison keys are equal, and vice versa. There is no requirement that the * comparison keys should reflect the ordering of the underlying objects. */ public ComparisonKey getComparisonKey(AtomicValue a) { return new ComparisonKey(a.getPrimitiveType().getFingerprint(), a); } }
/** * Get a comparison key for an object. This must satisfy the rule that if two objects are equal, * then their comparison keys are equal, and vice versa. There is no requirement that the * comparison keys should reflect the ordering of the underlying objects. */ public ComparisonKey getComparisonKey(AtomicValue a) { return new ComparisonKey(a.getPrimitiveType().getFingerprint(), a); } }