doest anyone knows a FREE EJB code generator?
I want to be able to generate home, remote, bean, PK and ejb-jar files from one description file.
Download Evaluation copy of Structure Builder from Webgain site..Do the required setting and map to the database for creating Entity Beans. Structure Builder creates the required Source file for U. Remote Interface, Home Interface, PK Class, Bean Class further to it, it creates a JAR file for Deployment too.
I use perculator which can be found at www.backsource.org. It is very configurable, generates all interfaces, entity beans, pks, proxy classes, makefiles, and deployment descriptors (jBoss and WebLogic). I did have to "fix" some stuff to get it to work with jBoss. As an example of how I use it, I had a bunch of beans deployed on jBoss built from perculator to which I wanted to add a generic sql query method. The method would take a string containing an sql statement, get a connection to the database, execute the query, and form the results into a collection of primary keys. I simply altered the template files used for generation (10 minutes), regenerated all the beans (uses super/impl pattern so really I regenerated all supers) (1 minute), and then executed a 'make deploy' which compiled all affected classes and hot deployed into jBoss. For 5 or more beans, I saved a couple hours of time while eliminating possibilities for typos, etc.