[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Blog post on limitations of import/include in W3C XML Sche
Anthony B. Coates writes: > Hi Noah. You seem to be talking about Schema *file* > repositories, I was certainly talking about Schema *definition* > repositories, which are not quite the same (just as the old IBM > "Visual Age for Java" product was different in the way it did > method-level versioning instead of file-level versioning). I don't think I missed that distinction. For XSD, we have schema document files for those who want a standard means of setting out schema definitions in a file, and we have schema components, which are the abstractions for element declarations, type definitions etc. I think the analogies to Java are pretty good: Java Source file <==> Schema Document Abstract class or method definition <===> schema component In fact, the schema Recommendation provides great flexibility as to whether Schema Documents are used. It allows for others to create specifications for repositories of various sorts, and those repositories can work at the level of schema documents, schema components, or some mixture. Now, what is true, is that components tend to live in a larger context. If I declare in a schema document: <simpleType name="t"> <xsd:restriction base="ns:b"> <xsd:length value="100"/> </xsd:restriction> </xsd:simpleType> that's not enough to uniquely determine a component. We also need to know the component that ns:b resolves to. So, while you can also make repositories that manage schema document fragments like the one above, they are not what we mean by a "component". Once you know that bs:b is a subtype of, say, string, then you'll know that this is a legal derivation, you'll know the base type chain, etc. This is quite analagous to defining a derived Java class; you don't know until you find the base class what the real signature of the derived class is, or whether in fact the derivation is legal. Noah -------------------------------------- Noah Mendelsohn IBM Corporation One Rogers Street Cambridge, MA 02142 1-617-693-4036 --------------------------------------
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] |
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|