Skip to Content.
Sympa Menu

xom-interest - Re: [XOM-interest] Shemp: an XMLFilter for use with XOM

xom-interest AT lists.ibiblio.org

Subject: XOM API for Processing XML with Java

List archive

Chronological Thread  
  • From: Elliotte Rusty Harold <elharo AT metalab.unc.edu>
  • To: John Cowan <cowan AT mercury.ccil.org>
  • Cc: Xom Interest <xom-interest AT lists.ibiblio.org>
  • Subject: Re: [XOM-interest] Shemp: an XMLFilter for use with XOM
  • Date: Wed, 18 Jun 2003 10:29:43 -0400

At 9:38 AM -0400 6/18/03, John Cowan wrote:


How clever would this be? If I returned an attribute, or text, where
you expected an element, would it become an attribute of/part of the
content of the parent element? If so, this would be a Good Thing for
architectural forms support.


Attributes are tricky. I can't really allow an Attribute to replace an Element without extra instanceof tests that are insanely expensive. Plus returning the attribute instead of an element, it would be very tricky to figure out the appropriate value of the attribute. I guess the factory would have to hang on to a reference to the Attribute object, and then accumulate text until it saw the end of the element, and then set the value. Messy, but doable.
--

Elliotte Rusty Harold
elharo AT metalab.unc.edu
Processing XML with Java (Addison-Wesley, 2002)
http://www.cafeconleche.org/books/xmljava
http://www.amazon.com/exec/obidos/ISBN%3D0201771861/cafeaulaitA




Archive powered by MHonArc 2.6.24.

Top of Page