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

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   RE: How do XML NameSpace aware processors react to NS definations?

[ Lists Home | Date Index | Thread Index ]
  • From: Ronald Bourret <rbourret@ito.tu-darmstadt.de>
  • To: xml list <xml-dev@ic.ac.uk>
  • Date: Thu, 19 Nov 1998 10:18:37 +0100

Amit Rekhi wrote:

> Ronald Bourret wrote:
>
> > If by "validating the namespaces" you mean checking that the prefix 
used in
> > the element or attribute name has been declared, it seems more 
appropriate
> > that if the parser claims to be namespace-aware, it would perform this
> > task.  Similarly, if the parser was a validating parser, it would also 
do any validation.
>
> Assuming that the parser is a validating NS aware parser,
> I was wondering what other validations could the parser perform.
>
> * It would be difficult for the parser to validate the content model,
> attributes of all the prefixed names against their definations in the DTD
> since the Namespace URI only signifies a unique identifier, nothing 
more.So
> validating prefixed names in the way given above would be difficult.
> Am I right?
> Then what other validations are left which are relevant to namespaces?

You are confusing two different things: validation (meaning to enforce the 
validity constraints in the XML spec) and enforcing the namespace 
constraints in the namespaces spec.  These are completely independent of 
each other.

The program that processes the namespaces must enforce the namespace 
constraints.  Generally, this will be the parser or a layer (such as John 
Cowan's namespace parser filter) built on top of the parser. In the case of 
a namespace-aware, validating parser, the parser enforces this.

The program that performs validation enforces the validity constraints. 
 This is usually a validating parser.  This program gets the information to 
validate against from the DTD.  It gets the DTD from the DOCTYPE statement; 
the DOCTYPE statement always points to the DTD, regardless of whether 
namespaces are used or not.  As you point out, the parser does not get the 
DTD from the namespace URI; the namespace URI is just a unique identifier 
and does not necessarily point to anything.

-- 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