There are already so many tools to automate this. With these tools you don't have to write ugly parsing code. Search for xml beans, jaxb, Castor. They all require schema to work on and then it will generate some stubs which are specific to your schema. These classes will be just like javabeans and you can call getter methods to extract the data.
In case your schema changes, you have to just run the tool again. /Ashwani -----Original Message----- From: Zhang, Larry (L.) [mailto:[EMAIL PROTECTED] Sent: Friday, February 23, 2007 3:13 AM To: Struts Users Mailing List Subject: Xml utilities I am trying to develop some classes used for XML parsing or generating purposes. But I think it is difficult to abstract to write a common utility since each XML document is different, and to parse that document, we should have a different parser. So the question is what utility class will look like so that it abstract some common methods/usage so that all the team members can use the utility class. If you can point me some example, that should be great. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This message contains information that may be privileged or confidential and is the property of the Capgemini Group. It is intended only for the person to whom it is addressed. If you are not the intended recipient, you are not authorized to read, print, retain, copy, disseminate, distribute, or use this message or any part thereof. If you receive this message in error, please notify the sender immediately and delete all copies of this message. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]