XML - Practical uses?

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: Trent Shipley
Date:  
Subject: XML - Practical uses?

> -----Original Message-----
> From:
> [mailto:plug-discuss-admin@lists.PLUG.phoenix.az.us]On Behalf Of Tom
> Bradford
> Sent: Thursday, June 21, 2001 12:32 PM
> To:
> Subject: Re: XML - Practical uses?
>
>
> Trent Shipley wrote:
> > So what was the point of SGML?
> >     XML is basically SGML-lite.

>
> There are some significant differences between the two. SGML has
> historically been used predominantly for document representation, while
> XML is being adopted more for data representation. Also, XML is very
> strict about nesting, case, and tag enclosure, where SGML can allow you
> to be very liberal with how you produce a document.


While there is some truth in this, I think it is overstated.

First, SGML is less machine friendly than XML, but its complex rules don't
actually make it human friendly. The O'Reily Nutshell handbook says that
several important SGML DTD, including DOCBOOK, are being re-defined, to the
extent possible, in XML. In general, there seems to be a consensus emerging
that one should not do in SGML what can be done in XML.

Second, the XML working group saw and evidently sees itself as primarily in
the business of defining a structural markup language for narrative text,
not a data structuring language. The Nutshell book says that the
applicability of XML to machine data formatting and data transmission is a
"happy accident".

>
> Regarding 'writing in XML'. XML is a syntax used for definining
> tag-based languages, and while those languages can be used for
> programming, they're typically used for representing complex and
> free-form data. The problem that most people encounter when approaching
> XML is that they think of it as an HTML replacement and it definitely is
> not. XHTML is an HTML replacement using XML.
>
> --
> Tom Bradford --- The dbXML Project --- http://www.dbxml.org/
> We store your XML data a hell of a lot better than /dev/null
> ________________________________________________



In fact, XML isn't a replacement for anything. It is a supplement to SGML.
Ultimately, XML is about defining subsets of XML (like XHMTL) that are then
written in the dialect of XML that you just defined. XML doesn't actually
*do* anything. It is just markup. If you want something interesting to
happen to an XML document you will need some applications....

As for programming in XML, there is no reason one couldn't write a DTD that
would be parsed, then handed to an application that generated machine code,
or interpreted the parse tree or stream as script instructions. Again with
the @#$% Nutshell Handbook, XSLT has been proven to be Turing complete, so
there already is an XML defined programming language out there, not that I'd
want to write an operating system kernel using it.