Folks- Bruce Snyder and myself have been further discussing how to go from the XML Schema to the JDO model for complete code generation in Castor. For those following this thread, Matz brought up the idea of using the source generator to generate the classes needed for JDO, and I mention that I'm doing that myself. Bruce brought up XDoclet (xdoclet.sourceforge.net) which can generate the mapping.xml file from the java source code via javadoc. After a some quick checks, here's the current score.
>From a single XML schema, generate the source code that can be use by JDO. Using annotations in the schema, generate the needed tags so xdoclet can produce the mapping.xml file from the resulting codebase. This combo allows the following to be produced from one XML schema file: -Java <-> XML marshaling source code -Object model -JDO Mapping file The only thing left missing is the SQL statements to auto-gen the tables. Granted, that's not a 'small' thing, but it seems like with that piece, this is one step away from being able to create an ant task that builds the entire substructure from one single XML Schema. Castor, front and back. Ok, now I'm looking for a dose or two of reality. What did I miss? I need comments positive and neg about this, if its a 'good thing(tm)'. Since one needs the tables names, field names/types to get XDoclet to generate the mapping.xml file in the first place, it seems like it shouldn't be too hard (famous last words) to also generate generic (or postgresql ;-) SQL code to auto-create the tables. This _seems_ not only doable, but quite useful. Speak up in the back! I can't hear you! ===== Virtually, | "Must you shout too?" Ned Wolpert | -Dante [EMAIL PROTECTED] | _________________/ "Who watches the watchmen?" 4e75 -Juvenal, 120 AD -- Place your commercial here -- fnord __________________________________________________ Do You Yahoo!? Great stuff seeking new owners in Yahoo! Auctions! http://auctions.yahoo.com ----------------------------------------------------------- If you wish to unsubscribe from this mailing, send mail to [EMAIL PROTECTED] with a subject of: unsubscribe castor-dev
