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

Re: SOX: element<->class mapping

  • From: David Brownell <db@E...>
  • To: "xml-dev@i..." <xml-dev@i...>
  • Date: Sat, 03 Oct 1998 10:33:54 -0700

class mapping
james anderson wrote:
> The point is, that the mapping between serial encoding and
> application data is best separated into two stages: encoding
> and application modeling.

Well, I'd claim "best" is a judgement that should be specific
to some application domain.  If the application is "element
oriented" (as many can be) this separation may be irrelevant.

> 	 For this purpose [1st stage] it
> suffices to declare a relation between java packages and xml
> namespaces and to use introspection to map from element name
> to class. One would have standard java packages appropriate
> for and associated with standard elements.

Of course with this sort of solution you prevent many-to-one
mappings.  Those can be convenient to work with.  If one must
take well formed XML and emit an HTML vocabulary, the ability
to have one class handle all of HTML's empty-element printing
syntax (e.g. <BR> or <BR /> but never <BR/>) is a time saver,
certainly at the "encoding" level and possibly higher up too.

Many other solutions for this exist.  For now, I'm assuming
a factory method createElement(uri,tag) that can have many
implementations, including the one james sketched above.

> The second (items 3 - 5 in the original note) is more complex.

Also, I'd claim, highly specific to the application structure.

I'd certainly agree that in the general case, XML will be
getting connected to some pre-existing application data which
calls for complex model transformations to become XML.  And
that a good XML applications framework must enable that!

However, I'd define the goals of an XML Object Framework to
be focussed a bit more closely on what Peter called "Element
Oriented Computing" ... where, I think, the assumption can
be made that least some elements are the natural focus of
an application.

- Dave

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...)


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.
First Name
Last Name
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.