Skip to Content.
Sympa Menu

xom-interest - [XOM-interest] Re: Welcome to the "XOM-interest" mailing list

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: xom-interest AT lists.ibiblio.org
  • Subject: [XOM-interest] Re: Welcome to the "XOM-interest" mailing list
  • Date: Wed, 18 Sep 2002 12:06:07 -0400

Welcome to the XOM-interest mailing list! Last night at the New York XML SIG meeting, I unveiled XOM, a new XML Object Model for Java published under the LGPL. Like DOM, JDOM, dom4j, and ElectricXML, XOM is a read/write API that represents XML documents as trees of nodes. Where XOM diverges from these models is that it strives for absolute correctness and maximum simplicity. XOM is based on more than two years' experience with JDOM development, as well as the last year's effort writing Processing XML with Java. While documenting the various APIs I found lots of things to like and not like about all the APIs, and XOM is my effort to synthesize the best features of the existing APIs while eliminating the worst. It's closest in spirit to JDOM. I had originally intended to fork JDOM, but it rapidly became apparent that very little actual JDOM code would be left when I was done and that starting from scratch would give me a flexibility I wouldn't have by using the existing JDOM code base. There is one non-public class hidden deep in the bowels of the API that uses some JDOM code (taken from, not coincidentally, the single JDOM class I was most personally responsible for) but otherwise, XOM was written starting with a blank screen.

I also attempted to write XOM according to a more modern understanding of Java in particular and API design in general than I had two years ago when JDOM was started. I've spent a lot of time over the last year thinking about the ideas of (and in some cases arguing with) Bruce Eckel, Joshua Bloch, Bertrand Meyer, Ken Arnold, Erich Gamma, Kent Beck, Martin Fowler, and other design savants, sometimes in person, sometimes in e-mail, sometimes just in my own head. It may not be obvious at first glance, but these gurus collectively had a huge effect on the overall design of the API. For instance, Joshua Bloch's Effective Java gave me the courage to ignore the Cloneable interface and give my classes copy constructors instead. Bloch and Bruce Eckel together convinced me that many of the exceptions in XOM deserved to be runtime exceptions, not checked exceptions, a decision that makes a lot of code much cleaner.
--

+-----------------------+------------------------+-------------------+
| Elliotte Rusty Harold | elharo AT metalab.unc.edu | Writer/Programmer |
+-----------------------+------------------------+-------------------+
| XML in a Nutshell, 2nd Edition (O'Reilly, 2002) |
| http://www.cafeconleche.org/books/xian2/ |
| http://www.amazon.com/exec/obidos/ISBN%3D0596002920/cafeaulaitA/ |
+----------------------------------+---------------------------------+
| Read Cafe au Lait for Java News: http://www.cafeaulait.org/ |
| Read Cafe con Leche for XML News: http://www.cafeconleche.org/ |
+----------------------------------+---------------------------------+



  • [XOM-interest] Re: Welcome to the "XOM-interest" mailing list, Elliotte Rusty Harold, 09/18/2002

Archive powered by MHonArc 2.6.24.

Top of Page