[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Standard XML APIs (was Re: CDATA by any other name...)

  • From: <david@m...>
  • To: XML Dev <xml-dev@i...>
  • Date: Tue, 3 Nov 1998 09:29:33 -0500 (EST)

xml standard cdata
Paul Prescod writes:

 > I find it odd that we can have "standard APIs" for the full
 > complexity of relational data, and probably eventually for object
 > database data, but it is perceived to be impossible to do the same
 > for the parse tree of XML data. I mean it is just annotated tree
 > structures: it shouldn't be rocket science (but neither is it
 > trivial).

Let's divide the use of XML into two fairly arbitrary groups
(acknowledging that there's considerable overlap):

1. Documents
2. Data

Group #1 (documents) is characterised by long sequences of mixed
content inside block-level containers (often paragraphs, but possibly
subtasks or steps in technical documentation); group #2 (data) is
characterised by fairly rigid hierarchies with plain character data
inside named fields (often, but not always, short) appearing in
predictable orders.

A standard XML-oriented API like the DOM is entirely suitable for
group #1, but the DOM is probably overkill for group #2, which
requires a domain-specific API (of course, for small or
non-speed-critical applications, the domain-specific API could be
implemented as an adapter on top of the DOM).

That said, you still need some kind of API to get at the XML to
populate the domain-specific model.  Sometimes, the DOM will be
appropriate, but given that many models in group #2 tend to be simple
and need to be processed on busy servers, a light-weight, event-based
API like XML::Parser or SAX usually makes the most sense for that
group.

Ideally, most programmers using XML for group #2 will never see an
XML-specific API -- we should hide it.


All the best,


David

-- 
David Megginson                 david@m...
           http://www.megginson.com/

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@i...
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/
To (un)subscribe, mailto:majordomo@i... the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo@i... the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa@i...)


PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.