[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [xml-dev] Re: determining ID-ness in XML
Elliotte Rusty Harold wrote:
> >Re-writing the DTDs is not workable.
> I totally disagree with this. XML applications and DTDs are rewritten
> all the time. MathML 1.0 begat MathML 2.0. SMIL 1.0 begat SMIL 2.0.
> XHTML 1.0 begat XHTML 1.1. DTDs change in order to add new
> functionality. If you don't want to change your DTD and you need
> valid documents, then you don't get the new functionality. You have a
> choice: update your DTD or don't use xml:id. I'm OK with that.
Elliotte, this simply isn't reality. Try telling a bank using XML as a feed to
their processing back-end that they need to add a new attribute to every element
in their DTD - the IT department will laugh you out of the building. Don't
bother trying to tell them that it won't break the existing system - they won't
take the chance. For organisations in that situation (and I know firsthand of a
number of them), the proposed solution of attributes is not appropriate. They
won't do it, especially when you can't provide them with one single benefit to
them. (Helping third parties isn't reason enough.)
> PIs also work, in part, especially if you imagine just one PI in the
> prolog listing all the ID attributes in the document. However, this
> tends to fail when documents start getting taken apart and put back
> together along with pieces of other documents. One of the goals for
> IDs/names instead of location based linking is that it's more robust
> against transforms. You can put multiple PIs inside elements or right
> before start-tags, but that's really messy, and still can't be easily
> made to survive an XSLT transform. Not impossible, of course. Just
Nobody AFAIK has suggested putting PIs anywhere except the top of the instance.
Since we seem not to have any widespread problem with fragmented instances and
DOCTYPE or XML declarations, I assume you don't view this as being any more
Marcus Carr email: email@example.com
Allette Systems (Australia) www: http://www.allette.com.au
"Everything should be made as simple as possible, but not simpler."