[OFFTOPIC] Re: [XML-SIG] XML-SCHEMA

Ken MacLeod ken@bitsko.slc.ut.us
24 Apr 2000 12:36:14 -0500


Christian Tismer <tismer@trixie.triqs.com> writes:

> Ken MacLeod wrote:

> > A common mistake in using XML, similar in spirit to XML Schema
> > being expressed in XML, is for people to access their application
> > data through a layer of XML exposed through DOM.  DOM is an
> > interface to XML information.  Accessing application data
> > represented via XML information is an unnecessary and burdensome
> > layer; far better to simply convert the XML into application
> > objects and use those directly.
> 
> Yes, right, but what's the point? Of course I would create
> application objects and validate them with the XML schema, which of
> course would be converted into some suitable application object
> before processing. It would make sense in the case of Schemas to
> build some mini-DOMs as an intermediate step, probably. But after
> the parsing, there is no more XML involved, just rules remain which
> check for presense, absense and correctness of attributes and
> elements. This happens in the moment where we create the application
> structure.

Yes, converting into suitable application objects before processing is
the right way to do it.  There are XML users who don't do that,
instead accessing their data through DOM, that's the wrong way to do
it.

  -- Ken