comp.lang.ada
 help / color / mirror / Atom feed
From: "Marc A. Criley" <mcNOSPAM@mckae.com>
Subject: Re: Experiences of XML parser generators for Ada?
Date: Mon, 6 Dec 2004 08:48:53 -0600
Date: 2004-12-06T08:48:53-06:00	[thread overview]
Message-ID: <31j9qpF3ask1jU1@individual.net> (raw)
In-Reply-To: 41b0f749$0$25068$ba620e4c@news.skynet.be

"Adrien Plisson" <aplisson-news@stochastique.net> wrote :
> so here comes my advice: think twice before using xml.
> xml is a very powerful tool for DYNAMICALLY STRUCTURED HUMAN READABLE
> TEXT.

Like any other technology, XML is well-suited to a certain class of problem
domains and not so well suited to others.  I agree that XML was an
inappropriate choice for the purpose to which you were applying it--internal
data transfer between two tightly coupled subsytems.

The reason for XML's existence is quite public:  data interoperability
between loosely coupled systems.  The human readability of XML is handy, but
basically irrelevant to its intended purpose.

As a real-world example, one of the tools we've developed at my day job
generates a report of events extracted from log files and correlated with
the expected sequence of events.  I directed that the report be generated
using XML, which made it easier to convert to HTML for viewing in a browser,
and to ease the creation of possible follow-on tools that might find the
information in that report to be useful as input.

Guess what?  This has just happened.  A new tool is now being created will
use the generated report as input, since the correlated, logged events can
serve as triggers as to when to perform additional post-processing of the
data logged by the system.  Because the report is represented in XML, no
parser needed to be written and no interpretation of the contents needed to
be implemented, it was all there in the XML schema and files.  Other than us
developers, no one will ever need to look at the raw XML form of the report,
but because of the interoperability infrastructure we have with XML, writing
and parsing data files comprises only a very small part of the overall
development effort.

> for everything else, a basic binary protocol with some well
> defined rules to follow (endianness, size of data) will really be more
> efficient. plus, a basic binary protocol do not need complicated
parsers...

Assuming of course that over time the documentation of the binary format
remains up-to-date and locatable!  At least with a halfway-reasonable XML
definition you can infer something about the content's layout and structure
just by looking at the file.  (And XML parsers are readily available, so
their complexity is of little concern to me.)

On-topic Ada reference :-) --  XIA (XPath In Ada) is coming along nicely.
The next version, 0.30, which includes a partial implementation of predicate
filtering, will be made available in the very near future.
(www.mckae.com/xia.html)

Marc A. Criley
McKae Technologies
www.mckae.com





  parent reply	other threads:[~2004-12-06 14:48 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-12-02 21:04 Experiences of XML parser generators for Ada? Daniel W
2004-12-02 22:19 ` Georg Bauhaus
2004-12-03  8:57 ` Martin Krischik
2004-12-03  9:16   ` Adrien Plisson
2004-12-03 20:42     ` Daniel W
2004-12-03 23:33       ` Adrien Plisson
2004-12-04  8:05         ` Dmitry A. Kazakov
2004-12-04 11:40           ` Marius Amado Alves
2004-12-04 13:14             ` Martin Krischik
2004-12-05 16:27               ` Jeffrey Carter
2004-12-05 17:58                 ` Dmitry A. Kazakov
2004-12-04 13:59             ` Georg Bauhaus
2004-12-05  8:47               ` Martin Krischik
2004-12-06 11:18                 ` Georg Bauhaus
2004-12-06 18:12                 ` Pascal Obry
2004-12-13 20:34                   ` Florian Weimer
2004-12-05  1:50             ` David Botton
2004-12-04 14:01           ` Georg Bauhaus
2004-12-04 16:27             ` Dmitry A. Kazakov
2004-12-06  5:59         ` Daniel W
2004-12-06 14:48         ` Marc A. Criley [this message]
     [not found] <20041203110026.6F40B4C408A@lovelace.ada-france.org>
2004-12-03 23:18 ` Robert C. Leif
2004-12-07 19:41   ` Björn Persson
  -- strict thread matches above, loose matches on Subject: below --
2004-12-04 20:37 Robert C. Leif
2004-12-04 22:53 ` Adrien Plisson
2004-12-08 23:37   ` Lionel Draghi
2004-12-09 12:29     ` Georg Bauhaus
2004-12-09 21:04       ` Lionel Draghi
2004-12-09 21:09     ` Lionel Draghi
2004-12-10 22:09     ` Simon Wright
2004-12-11  0:02       ` Lionel Draghi
2004-12-11  9:03         ` Pascal Obry
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox