Announcement Announcement Module
Collapse
No announcement yet.
If parent XSD imports many other XSD, is it sufficient to only include parent XSD? Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • If parent XSD imports many other XSD, is it sufficient to only include parent XSD?

    I have a scenario where a XSD (e.g. A.xsd) imports many other (children) XSDs. The child XSDs have different namespace. Source of all the XSDs(parent and many childern) is avialable and under the classpath.

    My question: Will it be suffifient to only specifiy the parent XSD and will that in turn will find all the children XSD? Or, do I need to specify all the multiple children also?

    The parent and children XSDs all have different namespaces.

    If I specify only one (parent) XSD, the code will be similar to:

    Code:
    <bean id="mySchemaCollection" class="org.springframework.xml.xsd.commons.CommonsXsdSchemaCollection">
    	<property name="inline" value="true" />
    	<property name="xsds">
    		<list>
    			<value>classpath:/myParent.xsd</value>
    		</list>
    	</property>
    </bean>
    An answer to my question is, "try it out yourself". But some insight to how it should be done/standard practice will be helpful.

  • #2
    Mine don't have different namespaces in included XSD's; but, yes, I only specify the top-most XSD file in my schema collection bean definition.

    FWIW, HTH. Thanks.

    Comment

    Working...
    X