OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Namespace: what's the correct usage?

Hi Jonathan,

> Martin Gudgin wrote:
>> [MJG]
>> The piece you are missing is that the default value of
>> elementFormDefault is 'unqualified'
> I didn't miss that. What I don't understand is how this value would
> be _different_ for the "person" and "given" element decls given the
> definition in the rec. i.e. none of the elements should be
> qualified. that's ok by me, all I am saying is that they should all
> be in the same namespace (and I am considering elements in no
> namespace to be in the 'same' namespace).

In XML Schema, the target namespace for elements declared as direct
children of the schema element (global declarations) is defined
differently than it is for elements declared further down (local
declarations).  The rec says:

  "If the <element> element information item has <schema> as its
  parent, the corresponding schema component is as follows:
  {target namespace}
  The ·actual value· of the targetNamespace [attribute] of the parent
  <schema> element information item, or ·absent· if there is none."

So global element declarations hook directly into the targetNamespace
for the schema, while the target namespace of local element
declarations is conditional on the 'form' attribute or
'elementFormDefault' attribute.

(Note that there's a mistake in the definition of target namespace for
locally scoped elements - it refers to a 'parent <schema> element'
when it means the 'ancestor <schema> element'.)



Jeni Tennison