axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jochen Wiedmann <>
Date Fri, 28 Nov 2003 06:56:11 GMT

Hi, Srinath,

Srinath Perera wrote:

> 1)Is there any way to set the root directory for the XSParser ..Problem
> comes when A.wsdl import B.wsdl and B.wsdl import C.xsd and the C is
> added as a DOM element the Parser serch for the C.xsd relative to A's
> location.

I would suggest to extend the XsObjectFactory and implement the
method XsObjectFactory.newXMLReader(). The implementation would
invoke super.newXMLReader() and set an instance of EntityResolver
on the result.

> 2)say there is a upper level element in Schema like
> <schema>
> 	<element name="x" type="y" maxOccurs="c"/>
> 	......
> </schema>

A top level element (as opposed to a local element, which
is embedded in a particle) MUST NOT have a maxOccurs attribute.
See the following excerpt from the schema of XML schema:

   <xs:complexType name="topLevelElement">
       <xs:restriction base="xs:element">
           <xs:element ref="xs:annotation" minOccurs="0"/>
           <xs:choice minOccurs="0">
             <xs:element name="simpleType" type="xs:localSimpleType"/>
             <xs:element name="complexType" type="xs:localComplexType"/>
           <xs:group ref="xs:identityConstraint" minOccurs="0"
         <xs:attribute name="ref" use="prohibited"/>
         <xs:attribute name="form" use="prohibited"/>
         <xs:attribute name="minOccurs" use="prohibited"/>
         <xs:attribute name="maxOccurs" use="prohibited"/>
         <xs:attribute name="name" use="required" type="xs:NCName"/>


View raw message