[jdom-interest] Philosophical XML (was API Inertia)

Rosen, Alex arosen at silverstream.com
Wed May 2 08:01:33 PDT 2001


> In my mind, XML is very simple:

If only. The XML that you or I would design from scratch would be very simple,
but unfortunately that's not what the real XML is. The real XML has a lot of
devil in the details, because (1) it derives from and is compatible with SGML,
which is very complicated, and (2) it was designed for many different uses,
from writing a magazine article to storing rows in a database, so it's not
ideal for either one. Someone else suggested it would be possible to learn XML
just by examining a well-constructed JDOM API; I think this is a bad idea -
there are enough gotchas in XML that you really need to learn it better than
that. The whitespace handling alone causes endless problems and
misunderstandings.

> A document contains a root element and
> other XML stuff (which isn't important in this discussion).

Unfortunately that's not true. The other children of a document (or an element)
are part of XML and part of JDOM. Many people think they should be nodes, but
some don't. There's still no agreement as to what should be a node and what
shouldn't.

Alex



More information about the jdom-interest mailing list