From: Joachim B. <jba...@pi...> - 2006-03-06 07:07:54
|
Hi there, since when does JSynthLib depend on JDom? This weekend I tried to compile the newest JSynthLib from the CVS source and got an error message because I don't have JDom installed. IMHO JSynthLib shouldn't use external libraries if it cannot be avoided. Cheers, Joachim |
From: Joe E. <jo...@em...> - 2006-03-06 09:29:09
Attachments:
smime.p7s
|
Joachim Backhaus wrote: > since when does JSynthLib depend on JDom? > Please see my post to the developers' list dated Feb 22. 2006, when I added XML saving of patch data. > This weekend I tried to compile the newest JSynthLib > from the CVS source and got an error message because > I don't have JDom installed. > I thoughts I added the jdom.jar to CVS. So you should only need to include it in your classpath along with groovy.jar. > IMHO JSynthLib shouldn't use external libraries if > it cannot be avoided. > I agree whole-heartedly. However, JDOM was the only sensible object-oriented XML library I could find for Java. Plain Java has SAX and DOM parsers built-in, but all of the examples I've seen for them are very ugly. Indeed, *some* of the examples I saw for *writing* XML with the built-in SAX and DOM didn't even *use* the XML classes at *all*. They just use print statements to print the XML directly... leaving the developer responsible for all formatting and well-formedness issues (like this one: http://www.cafeconleche.org/books/xmljava/chapters/ch03s02.html). Meanwhile, JDOM allows for the developer to deal with the XML document in a completly object-oriented manner. It's so much of an improvement that some are expecting that JDOM will eventually be incorporated into J2SE (http://www.jcp.org/en/jsr/results?id=93). So, part of why I decided to include jdom.jar is because I expect that, someday, we'll be able to remove it when JDOM (or some other object-oriented XML suite) becomes part of the standard J2SE implementation. Lastly, I included it because *somebody* (cough, cough...) already included groovy.jar... and that's about 10x as big as jdom.jar. - Joe |
From: Christoph E. <ce...@ch...> - 2006-03-07 18:07:27
|
Hi, > I thoughts I added the jdom.jar to CVS. So you should only need to > include it in your classpath along with groovy.jar. I downloaded the jdom.jar binary. Any hints where to place and where to include it? Thanks, ce |
From: Joe E. <jo...@em...> - 2006-03-06 12:29:53
Attachments:
smime.p7s
|
Joe Emenaker wrote: > It's so much of an improvement that some are expecting that JDOM will > eventually be incorporated into J2SE > (http://www.jcp.org/en/jsr/results?id=93). So, part of why I decided > to include jdom.jar is because I expect that, someday, we'll be able > to remove it when JDOM (or some other object-oriented XML suite) > becomes part of the standard J2SE implementation. I stand corrected. It turns out that the author of JDOM has withdrawn their bid to get JDOM included in J2SE (http://www.jdom.org/pipermail/jdom-interest/2004-September/014191.html). This leaves me with four courses of action (in increasing preference): 1 - Leave jdom.jar in JSL. (This is the option I like least) 2 - Convert my code in JSL that does XML stuff to use JAXP 3 - Get the source code for JDOM and actually include just the parts that I need to use into the actual JSL source tree (license permitting). 4 - Write my own classes that behave like JDOM (ie, they would have an object-oriented front-end while using the yucky JAXP-DOM classes for the actual work). I'll have to take another look at JAXP and see how distasteful it is and then I'll decide. - Joe |
From: Rib R. <ri...@gm...> - 2006-03-06 17:42:35
|
On 3/6/06, Joe Emenaker <jo...@em...> wrote: > Joe Emenaker wrote: > > It's so much of an improvement that some are expecting that JDOM will > > eventually be incorporated into J2SE > > (http://www.jcp.org/en/jsr/results?id=3D93). So, part of why I decided > > to include jdom.jar is because I expect that, someday, we'll be able > > to remove it when JDOM (or some other object-oriented XML suite) > > becomes part of the standard J2SE implementation. > I stand corrected. It turns out that the author of JDOM has withdrawn > their bid to get JDOM included in J2SE > (http://www.jdom.org/pipermail/jdom-interest/2004-September/014191.html). > > This leaves me with four courses of action (in increasing preference): > > 1 - Leave jdom.jar in JSL. (This is the option I like least) > 2 - Convert my code in JSL that does XML stuff to use JAXP > 3 - Get the source code for JDOM and actually include just the parts > that I need to use into the actual JSL source tree (license permitting). > 4 - Write my own classes that behave like JDOM (ie, they would have an > object-oriented front-end while using the yucky JAXP-DOM classes for the > actual work). > > I'll have to take another look at JAXP and see how distasteful it is and > then I'll decide. I've already worked on something like #4 for the XML driver (although it's not based on the JDOM api or anything like that). If I have time I'll try to look at the stuff you've added and see how hard it would be to convert to use the XML driver's SAX parser. And on a side note, Groovy seems to be on schedule with their plans for integration into J2SE. |