| Author |
Journal Article - The Trail Guide - The three rules of using XML and Java
|
Dirk Schreckmann
Sheriff
Joined: Dec 10, 2001
Posts: 7023
|
|
The just-released September 2004 edition of The JavaRanch Journal includes an article by Paul Wheaton, "The Trail Guide - The three rules of using XML and Java". Please use this thread to comment on and discuss the article.
|
[How To Ask Good Questions] [JavaRanch FAQ Wiki] [JavaRanch Radio]
|
 |
Daniel Mayer
Ranch Hand
Joined: Sep 09, 2004
Posts: 103
|
|
Personally, I prefer Dom4J over JDom. It seems to have the more complete API, while still coming natural to a Java developer. And I see one drawback using an XML-serializer like XStream - The XML structure is only implicitely defined by the object structure, so by refactoring your design, you can accidentally become incompatible to prior versions. For things like configuration files I therefore prefer to define the XML structure via a schema and let the java classes be generated from it; for example using JAXB.
|
 |
Gregg Bolinger
Ranch Hand
Joined: Jul 11, 2001
Posts: 15230
|
|
Paul, thanks for mentioning XStream. I'll be able to put this to good use. Oh wait, we aren't suppose to use XML are we?
|
 |
Vladas Razas
Ranch Hand
Joined: Dec 02, 2003
Posts: 385
|
|
Haha, I fell at rule 2 and 3. Using regular DOM... But it was worth it because I better understood XML now. Had to deal with whitespace text nodes etc myself Regards
|
 |
 |
|
|
subject: Journal Article - The Trail Guide - The three rules of using XML and Java
|
|
|