Hi, For XML processing I would not use Xerces directly. I would look into JAXB (Xml data binding). In this area you can look into Castor (www.exolab.com). Castor does not implement JAXB spec, but following the same idea and works well. Also you can look into Digester from appache-commons. Finally if you choose to process XML "manualy" I would use DOM4J as a lelel of abstraction on top of Xerces.
Alexi --- Gonzalo Diethelm <[EMAIL PROTECTED]> wrote: > [Sorry, this is off-topic. I just want to tap into > the knowledge pool > in this list. Please feel free to ignore.] > > Three probably basic questions: > > 1. I need to process XML files having this shape: > > <data> > <record> > [data for this record, with attributes, nested > tags, etc.] > </record> > <record> > ... > </record> > ... > </data> > > I have to process the file, convert each record > into an object of > a specific class that holds all the info for that > record, and call > some kind of business logic for that record (one > record at a time). > I guess I can use Xerces for this, but should I > use SAX(2)? DOM? > Anything newer? Something in commons or Avalon > that abstracts this > even more? > > 2. I need to process data files with (potentially) > multiple formats. > The only format I know for sure will exist is > fixed-length fields: > > 20021225Christmas.......Buy.present.for.Mom... > 20021111Birthday........Go.out.and.party...... > etc. > > where the '.' characters are really spaces, > changed to show that > each field is fixed length. The idea would be to > read each record, > create an object of a given class that > encapsulates it, and call > business logic for it (again, one record at a > time). Are there any > Java libraries to handle this kind of task? > > 3. The eternal object-relational mapping. I have > been reading on OJB, > and I like what I know so far. The question here > is: at what level > should I use it? The basic Persistence Broker > API? The ODMG API? > The JDO API, even thought it is not completely > stable yet? Or should > I use a totally different library? For example, I > have used Torque > before (from the Turbine project), but I view > that as a more > Turbine-related library, and this will not be a > Turbine application. > > Thanks very much for any insight, and sorry again > for being off-topic. > > > -- > Gonzalo A. Diethelm > [EMAIL PROTECTED] > > > -- > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > __________________________________________________ Yahoo! - We Remember 9-11: A tribute to the more than 3,000 lives lost http://dir.remember.yahoo.com/tribute -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>