You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by bu...@apache.org on 2001/08/08 02:01:53 UTC

[Bug 3035] New: - Cannot parse schema for schema

PLEASE DO NOT REPLY TO THIS MESSAGE. TO FURTHER COMMENT
ON THE STATUS OF THIS BUG PLEASE FOLLOW THE LINK BELOW
AND USE THE ON-LINE APPLICATION. REPLYING TO THIS MESSAGE
DOES NOT UPDATE THE DATABASE, AND SO YOUR COMMENT WILL
BE LOST SOMEWHERE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=3035

*** shadow/3035	Tue Aug  7 17:01:53 2001
--- shadow/3035.tmp.26812	Tue Aug  7 17:01:53 2001
***************
*** 0 ****
--- 1,64 ----
+ +============================================================================+
+ | Cannot parse schema for schema                                             |
+ +----------------------------------------------------------------------------+
+ |        Bug #: 3035                        Product: Xerces-J                |
+ |       Status: NEW                         Version: 1.4.2                   |
+ |   Resolution:                            Platform: All                     |
+ |     Severity: Major                    OS/Version: All                     |
+ |     Priority: Other                     Component: Schema-Structures       |
+ +----------------------------------------------------------------------------+
+ |  Assigned To: xerces-j-dev@xml.apache.org                                  |
+ |  Reported By: tkamiya@iona.com                                             |
+ +----------------------------------------------------------------------------+
+ |          URL:                                                              |
+ +============================================================================+
+ |                              DESCRIPTION                                   |
+ Hi,
+ 
+ To validate a schema against "schema for schema" for syntactic correctness,
+ I needed to let TraverseSchema class be able to parse "schema for schema".
+ 
+ I found a problem which relates to the fact that schema for schema contains
+ several utility types not for public use. One example of such utility types
+ is (which is an excerpt from datatypes.xsd):
+ 
+  <xs:simpleType name="derivationControl">
+   <xs:annotation>
+    <xs:documentation>
+    A utility type, not for public use</xs:documentation>
+   </xs:annotation>
+   <xs:restriction base="xs:NMTOKEN">
+    <xs:enumeration value="substitution"/>
+    <xs:enumeration value="extension"/>
+    <xs:enumeration value="restriction"/>
+    <xs:enumeration value="list"/>
+    <xs:enumeration value="union"/>
+   </xs:restriction>
+  </xs:simpleType>
+ 
+ To handle utility types, the following changes to TraverseSchema were found to 
+ be
+ necessary.
+ 
+     public DatatypeValidator getDatatypeValidator(String uri, String localpart) 
+ {
+ 
+         DatatypeValidator dv = null;
+ 
+         if (uri.equals(SchemaSymbols.URI_SCHEMAFORSCHEMA)) {
+             dv = fDatatypeRegistry.getDatatypeValidator( localpart );
+         }
+ /**
+  * tkamiya - 2001-08-06
+         else {
+             dv = fDatatypeRegistry.getDatatypeValidator( uri+","+localpart );
+         }
+ */
+ 
+         if (dv == null)
+           dv = fDatatypeRegistry.getDatatypeValidator( uri+","+localpart );
+ 
+         return dv;
+     }
+ 
+ -Takuki Kamiya
\ No newline at end of file

---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-dev-help@xml.apache.org