http://nagoya.apache.org/bugzilla/show_bug.cgi?id=2326 *** shadow/2326 Tue Jun 26 06:44:54 2001 --- shadow/2326.tmp.24929 Tue Jun 26 06:44:54 2001 *************** *** 0 **** --- 1,67 ---- + +============================================================================+ + | <import> with NO schemaLocation="..." reports error | + +----------------------------------------------------------------------------+ + | Bug #: 2326 Product: Xerces-J | + | Status: NEW Version: 1.4 | + | Resolution: Platform: PC | + | Severity: Normal OS/Version: Windows NT/2K | + | Priority: Other Component: Schema-Structures | + +----------------------------------------------------------------------------+ + | Assigned To: [EMAIL PROTECTED] | + | Reported By: [EMAIL PROTECTED] | + | CC list: Cc: | + +----------------------------------------------------------------------------+ + | URL: | + +============================================================================+ + | DESCRIPTION | + The namespace="..." and schemaLocation="..." attributes on an <import> item are + both OPTIONAL. However, the parser throws an error: + + "Schema error: Could not get the doc root for imported Schema file: ,." + + when an <import> item is missing schemaLocation="...". Here's an example: + + 4_2_3v09.xsd + ============ + <schema xmlns ="http://www.w3.org/2001/XMLSchema" + targetNamespace="http://www.Test.org/4_2_3sv"> + + <import namespace="http://www.Test.org/4_2_3svimp"/> + + <element name="root"> + <complexType> + <sequence> + <any namespace="http://www.schemaTest.org/ibm4_2_3svimp" + processContents="lax" minOccurs="0" maxOccurs="unbounded"/> + </sequence> + <anyAttribute namespace="http://www.schemaTest.org/ibm4_2_3svimp" + processContents="lax"/> + </complexType> + </element> + + </schema> + + 4_2_3v09.xml + ============ + <?xml version="1.0"?> + <sv:root xmlns:xsi ="http://www.w3.org/2001/XMLSchema-instance" + xmlns:svimp ="http://www.Test.org/4_2_3svimp" + xmlns:svimp2 ="http://www.Test.org/4_2_3svimp2" + xmlns:sv ="http://www.Test.org/4_2_3sv" + xsi:schemaLocation="http://www.Test.org/4_2_3sv + 4_2_3v09.xsd" + svimp:string="string" svimp:int="10"> + + <svimp:AnyElem>Any elements from "svimp:" are allowed here. + <Child/> + <svimp2:Child>10</svimp2:Child> + <svimp:Child>some text</svimp:Child> + </svimp:AnyElem> + + <svimp:AnyElem> + <Child/> + </svimp:AnyElem> + + <svimp:AnyElem2>Any elements from "svimp:" are allowed here.</svimp:AnyElem2> + + </sv:root> \ No newline at end of file --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
