Thursday, November 26, 2020

Import vs Include

 What is the difference between include and import?

You must use <import> to refer to declarations or definitions that are in a different target namespace.

You must use <include> to refer to declarations or definitions that are in the same or no target namespace.

Valid: 

<xsd:import namespace=”some/name/space”/> 
<xsd:import schemaLocation=”classpath://mine.xsd”/> 

<xsd:include schemaLocation=”classpath://mine.xsd”/>

 Invalid: 

<xsd:include namespace=”some/name/space”/>


No comments:

Post a Comment

Import vs Include

 What is the difference between include and import? You must use <import> to refer to declarations or definitions that are in a differ...