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

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Re: Namespaces/XSchema Spec - XSchema Element (Sections 2.0 and 2.1),

[ Lists Home | Date Index | Thread Index ]
  • From: rbourret@dvs1.informatik.tu-darmstadt.de (Ron Bourret)
  • To: xml-dev@ic.ac.uk
  • Date: Thu, 6 Aug 1998 12:35:13 +0200

Simon St. Laurent wrote:
> > There are other fun things we could do, like adding an attribute to
> > XSC:XSchema elements that identifies the namespace in which they live via 
the
> > URN (forget the prefix), 

John Cowan wrote:
> After mulling it for several days, I think this is the Right Thing.
> Add an #IMPLIED "ns" attribute to ElementDecl and AttDef elements
> whose value is an URI.  XSchema validation can then proceed with
> respect to the actual URIs, and disregarding the actual prefixes
> used in particular documents.  This gives XSchemas a leg-up on DTDs,
> which are bound to specific prefixes in the name of SGML
> (and XML 1.0) compatibility.

Toby Speight wrote:
> This sounds good - do we want to include a "suggested prefix" (to
> facilitate conversion to DTD format when possible)?  Or perhaps use
> the fully-prefixed form in the XSchema, and ignore it for direct
> XSchema processing?

Just to be clear, the proposal is as follows:

1) The Namespace element goes away.

2) We add the following attributes:

   <!ATTLIST XSchema
      ...
      ns CDATA #IMPLIED
      prefix NMTOKEN #IMPLIED>

   <!ATTLIST ElementDecl
      ...
      ns CDATA #IMPLIED
      prefix NMTOKEN #IMPLIED>

   <!ATTLIST AttList
      ...
      ns CDATA #IMPLIED
      prefix NMTOKEN #IMPLIED>

The ns attribute states which namespace the element/attribute being declared 
belongs to.  Thus, when validating an instance file, the validator resolves the 
prefix in the instance file and checks that the element/attribute matches the 
definition for that element/attribute in the namespace identified by the ns 
attribute.

The prefix attribute is used only by the XSchema-to-DTD converter; if it is 
missing, the converter either makes up a prefix or does not use a prefix.  (Note 
that we cannot set the ns attribute during DTD-to-XSchema conversion because we 
do not know what namespace applies to which prefix; this information is 
specified in the instance, not the DTD.  For people who agreed to be unabusive 
about their prefix->namespace mappings, we could define a PI for use in the 
DTD.)

If this is the case, I am in complete agreement.

-- Ron Bourret

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@ic.ac.uk
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/
To (un)subscribe, mailto:majordomo@ic.ac.uk the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo@ic.ac.uk the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa@ic.ac.uk)





 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS