< prev index next >

src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/XSSimpleTypeDecl.java

Print this page

        

*** 1,8 **** /* * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. ! * @LastModified: Oct 2017 */ /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. --- 1,8 ---- /* * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. ! * @LastModified: Nov 2017 */ /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership.
*** 233,243 **** return Locale.getDefault(); } }; protected static TypeValidator[] getGDVs() { ! return (TypeValidator[])gDVs.clone(); } private TypeValidator[] fDVs = gDVs; protected void setDVs(TypeValidator[] dvs) { fDVs = dvs; } --- 233,243 ---- return Locale.getDefault(); } }; protected static TypeValidator[] getGDVs() { ! return gDVs.clone(); } private TypeValidator[] fDVs = gDVs; protected void setDVs(TypeValidator[] dvs) { fDVs = dvs; }
*** 432,442 **** fTargetNamespace = uri; fFinalSet = finalSet; fAnnotations = annotations; fVariety = VARIETY_LIST; ! fItemType = (XSSimpleTypeDecl)itemType; fValidationDV = DV_LIST; fFacetsDefined = FACET_WHITESPACE; fFixedFacet = FACET_WHITESPACE; fWhiteSpace = WS_COLLAPSE; --- 432,442 ---- fTargetNamespace = uri; fFinalSet = finalSet; fAnnotations = annotations; fVariety = VARIETY_LIST; ! fItemType = itemType; fValidationDV = DV_LIST; fFacetsDefined = FACET_WHITESPACE; fFixedFacet = FACET_WHITESPACE; fWhiteSpace = WS_COLLAPSE;
*** 542,552 **** fTargetNamespace = uri; fFinalSet = finalSet; fAnnotations = annotations; fVariety = VARIETY_LIST; ! fItemType = (XSSimpleTypeDecl)itemType; fValidationDV = DV_LIST; fFacetsDefined = FACET_WHITESPACE; fFixedFacet = FACET_WHITESPACE; fWhiteSpace = WS_COLLAPSE; --- 542,552 ---- fTargetNamespace = uri; fFinalSet = finalSet; fAnnotations = annotations; fVariety = VARIETY_LIST; ! fItemType = itemType; fValidationDV = DV_LIST; fFacetsDefined = FACET_WHITESPACE; fFixedFacet = FACET_WHITESPACE; fWhiteSpace = WS_COLLAPSE;
*** 881,893 **** ValidationContextImpl ctx = new ValidationContextImpl(context); enumerationAnnotations = facets.enumAnnotations; fEnumerationSize = 0; for (int i = 0; i < size; i++) { if (enumNSDecls != null) ! ctx.setNSContext((NamespaceContext)enumNSDecls.get(i)); try { ! ValidatedInfo info = getActualEnumValue((String)enumVals.get(i), ctx, null); // check 4.3.5.c0 must: enumeration values from the value space of base fEnumeration[fEnumerationSize++] = info; } catch (InvalidDatatypeValueException ide) { reportError("enumeration-valid-restriction", new Object[]{enumVals.get(i), this.getBaseType().getName()}); } --- 881,893 ---- ValidationContextImpl ctx = new ValidationContextImpl(context); enumerationAnnotations = facets.enumAnnotations; fEnumerationSize = 0; for (int i = 0; i < size; i++) { if (enumNSDecls != null) ! ctx.setNSContext(enumNSDecls.get(i)); try { ! ValidatedInfo info = getActualEnumValue(enumVals.get(i), ctx, null); // check 4.3.5.c0 must: enumeration values from the value space of base fEnumeration[fEnumerationSize++] = info; } catch (InvalidDatatypeValueException ide) { reportError("enumeration-valid-restriction", new Object[]{enumVals.get(i), this.getBaseType().getName()}); }
*** 2602,2612 **** XSTypeDefinition type = this; while (!(ancestorName.equals(type.getName()) && ((ancestorNS == null && type.getNamespace() == null) || (ancestorNS != null && ancestorNS.equals(type.getNamespace())))) && // compare with ancestor type != fAnySimpleType) { // reached anySimpleType ! type = (XSTypeDefinition)type.getBaseType(); } return type != fAnySimpleType; } --- 2602,2612 ---- XSTypeDefinition type = this; while (!(ancestorName.equals(type.getName()) && ((ancestorNS == null && type.getNamespace() == null) || (ancestorNS != null && ancestorNS.equals(type.getNamespace())))) && // compare with ancestor type != fAnySimpleType) { // reached anySimpleType ! type = type.getBaseType(); } return type != fAnySimpleType; }
< prev index next >