sandygao    2003/01/21 11:14:06

  Modified:    java/src/org/apache/xerces/impl/msg
                        XMLSchemaMessages.properties
               java/src/org/apache/xerces/impl/xs/traversers
                        XSDHandler.java
  Log:
  Error code change as per Erratum E1-39.
  
  Revision  Changes    Path
  1.62      +3 -2      
xml-xerces/java/src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties
  
  Index: XMLSchemaMessages.properties
  ===================================================================
  RCS file: 
/home/cvs/xml-xerces/java/src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties,v
  retrieving revision 1.61
  retrieving revision 1.62
  diff -u -r1.61 -r1.62
  --- XMLSchemaMessages.properties      21 Jan 2003 17:54:35 -0000      1.61
  +++ XMLSchemaMessages.properties      21 Jan 2003 19:14:04 -0000      1.62
  @@ -157,7 +157,8 @@
           src-redefine.7.2.1 = src-redefine.7.2.1: no attributeGroup in the redefined 
schema with a name matching ''{0}''.
           src-redefine.7.2.2 = src-redefine.7.2.2: attributeGroup ''{0}'' does not 
properly restrict the attributeGroup it redefines; constraint violated:  ''{1}''.
           src-resolve = src-resolve: Cannot resolve the name ''{0}'' to a(n) {1} 
component.
  -        src-resolve.4 = src-resolve.4: Components from namespace ''{1}'' are not 
referenceable from schema document ''{0}''.
  +        src-resolve.4.1 = src-resolve.4.1: Components with no namespace are not 
referenceable from schema document ''{0}''.
  +        src-resolve.4.2 = src-resolve.4.2: Components from namespace ''{1}'' are 
not referenceable from schema document ''{0}''.
           src-restriction-base-or-simpleType = src-restriction-base-or-simpleType: 
error.
           src-simple-type.2 = src-simple-type.2: <restriction> must have a base 
[attribute] or a <simpleType> among its [children], but not both.
           src-simple-type.3 = src-simple-type.3: <list> must have an itemType 
[attribute] or a <simpleType> among its [children], but not both.
  
  
  
  1.62      +7 -4      
xml-xerces/java/src/org/apache/xerces/impl/xs/traversers/XSDHandler.java
  
  Index: XSDHandler.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xerces/java/src/org/apache/xerces/impl/xs/traversers/XSDHandler.java,v
  retrieving revision 1.61
  retrieving revision 1.62
  diff -u -r1.61 -r1.62
  --- XSDHandler.java   20 Jan 2003 19:45:25 -0000      1.61
  +++ XSDHandler.java   21 Jan 2003 19:14:05 -0000      1.62
  @@ -1062,8 +1062,10 @@
           // now check whether this document can access the requsted namespace
           if (!currSchema.isAllowedNS(declToTraverse.uri)) {
               // cannot get to this schema from the one containing the requesting decl
  -            if (currSchema.needReportTNSError(declToTraverse.uri))
  -                reportSchemaError("src-resolve.4", new 
Object[]{fDoc2SystemId.get(currSchema.fSchemaDoc), declToTraverse.uri}, elmNode);
  +            if (currSchema.needReportTNSError(declToTraverse.uri)) {
  +                String code = declToTraverse.uri == null ? "src-resolve.4.1" : 
"src-resolve.4.2";
  +                reportSchemaError(code, new 
Object[]{fDoc2SystemId.get(currSchema.fSchemaDoc), declToTraverse.uri}, elmNode);
  +            }
               return null;
           }
   
  @@ -1149,7 +1151,8 @@
           schemaWithDecl = findXSDocumentForDecl(currSchema, decl);
           if (schemaWithDecl == null) {
               // cannot get to this schema from the one containing the requesting decl
  -            reportSchemaError("src-resolve.4", new 
Object[]{fDoc2SystemId.get(currSchema.fSchemaDoc), declToTraverse.uri}, elmNode);
  +            String code = declToTraverse.uri == null ? "src-resolve.4.1" : 
"src-resolve.4.2";
  +            reportSchemaError(code, new 
Object[]{fDoc2SystemId.get(currSchema.fSchemaDoc), declToTraverse.uri}, elmNode);
               return null;
           }
           // a component is hidden, meaning either it's traversed, or being traversed.
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to