- From: Jeni Tennison <jeni@jenitennison.com>
- Date: Sat, 7 Sep 2002 08:55:16 +0100
- To: "Y. Han" <yhan@uwo.ca>
- CC: xmlschema-dev@w3.org
Hi, > Now I have two choices. The first one is [snip] > The first one is nested , while the second is seperated. Which one > is correct? or both are correct? You actually have three choices -- the third choice is to declare the elements globally and have anonymous (nested) types. These design patterns are known as "Russian Doll", "Venetian Blind" and "Salami Slice". You can learn more about them and their advantages and disadvantages at: http://www.xfront.com/GlobalVersusLocal.html My personal preference is to use a "Venetian Blind" pattern for most of a schema, with elements declared locally where possible and types declared globally. I don't think that the "Russian Doll" pattern is particularly good, except for very small schemas, because it leads to schemas that are hard to read (you lose track of where you are) and hard to extend/redefine by others. But as with most things, a judicious mix is probably the best policy. Cheers, Jeni --- Jeni Tennison http://www.jenitennison.com/
Received on Saturday, 7 September 2002 03:55:17 UTC