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

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Re: [xml-dev] Non-validating parser, non-existing DTD,undefined entity a

[ Lists Home | Date Index | Thread Index ]

> Section 2.9: XML 1.0 -- "Standalone="yes" indicates there are no external
> markup declarations that affect the information passed from the XML
> processor to the application"
> 
> -- Can I ask you once more whether you think specifying an external subset
> is legal?? -- doesn't an external subset imply that there are external
> markup declarations??

They're legal if they don't _affect_ the information provided.
Where the information affected is a small subset of what
a parser normally provides; for example it doesn't include
attribute or element typing information.

For example, it would be illegal for the external subset to have
a declaration that caused an attribute value to change because
of normalization.  But it would be legal if the value were already
normalized, but the declaration just told you its type was "ID".


> > Not so -- see the conformance section of the XML rec, it
> > allows non-validating parsers which read external entities.
> > In fact as I noted, such parser modes are typical in Java.
> >
> > As I said, a SAX parser that tries to read that WILL get
> > an error, which is of course allowed.
> 
> Yes, they may process external entities, but am I right if I say that --
> "A non-validating parser *need not* issue an error if the URI pointing to
> an external entity is invalid"?? -- again this is what I kind of
> understood from Section 5: Conformance of XML 1.0..

In the scenario that I described -- a SAX parser is configured
to process those enitities -- the parser does _need_ to issue
an error.  "A non-validating parser" in general need not, like
a SAX parser that doesn't recognize that feature setting.

But a SAX parser that's explicitly told to process those entities
had darn well better process them!!

- Dave






 

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

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