[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: targetNamespace and default namespace
On 9/29/2016 11:26 AM, Michael Kay wrote: Ah... I have probably in practice absorbed that bit without noticing ... thanks.On 29 Sep 2016, at 16:07, Thomas Passin<list1@tompassin.net> wrote: I have always understood that the elementFormDefault only applies to the way that the element names are written*in the schema*; if there is a target namespace specified, then all elements defined in the schema (and not otherwise namespaced or referenced) must be in that namespace in an instance document, unrelated to the value of elementFormDefault.No, that's incorrect. If you specify form="unqualified", or by implication elementFormDefault="unqualified", which is its default value, then local element declarations describe elements whose names are in no namespace. Probably doesn't help Rusty, though. TomP Chapter and verse: XSD 1.0 part 1 §3.3.2, Element information items ·validated· by a top-level declaration must be qualified with the {target namespace} of that declaration (if this is ·absent·, the item must be unqualified). Control over whether element information items ·validated· by a local declaration must be similarly qualified or not is provided by the form [attribute], whose default is provided by the elementFormDefault [attribute] on the enclosing <schema>, via its determination of {target namespace}. which says that if form=unqualified (explicitly or implicitly) the element information item to be validated must be unqualified, which is XSD's way of saying it must be in no namespace.
[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
|