>> GreenByte.info By Nick Tong (quiksilv) | Supported by: TalkWebSolutions.co.uk

A quick review on Brian Rinaldis code generator

So after my previous post about not being able to get flex running on my local dev machine I decided to give Brian Rinaldis CFC Object Generator (CFCOG, or as Brian likes to call it: Illudium PU-36 Code Generator) a test from another machine, and boy does it deliver.

First of though what is it:

This project generates ColdFusion components (i.e. bean, DAO, gateway, service), ColdSpring XML, Transfer XML, and ActionScript Value-Objects using the admin api and database introspection. The front-end is built in Flex 2. The code outputted for easily pasting or saving into a project to allow you to get a head-start on some of the grunt work of doing OO in CF. It uses XSL to generate the components and is designed to allow you to easily add to or modify the generated code. You can even create new templates that can be swapped out at run-time.

If you have the system requirements, you install the application and are presented with an intuitive interface:
screen shot 1

To get the app to generate code for you, you simply:

  • select the database you want
  • select the database table
  • select the template type (default, prototype or transfer)
  • select your CFC path
  • and select a path for your code output (used for saving generated code)
  • click generate

You will then get an output in the main area of the screen with your generated code. In my example I'm wishing to generate code for Mark Mandels Transfer frameworks and depending on which template type you are using you will get different tab outputs on the following screen. For transfer you get four tabs:

screen shot 2

  • Gateway - This generates gateway for your table object.
  • Service - This, as the name suggests generates your service layer (the business logic)
  • Transfer - This generates the business objects for the transfer framework configuration file
  • Coldspring - This generates the beans for the coldspring framework configuration file

For a default output you will these tabs

  • bean - setters and getters
  • dao - database actions dealing with a single record
  • gateway - returns query results
  • service - the business logic
  • to - (transfer object) used for transferring static data between objects
  • coldspring - Dependency injection framework beans

More information on how to use this app can be found here.

It's worth noting that the code generated is very generic and for it to really benefit you you may wish to customise the code output, read here on how to do just that.. I see the fact that you can customise the code output as one of the strong features for this application. I'm going to work on customization now and i'll let you know how I get on.


 
Comments
newbie's Gravatar i want to ask about the "select your CFC path" in your artical as i see you type in " com.ads " is this the cfc that you create for the table ads???
# Posted By newbie | 11/04/07 06:01 | Report abusive comment
wedding dress's Gravatar yes, I have the same problem.
# Posted By wedding dress | 11/03/08 02:14 | Report abusive comment
buy wow gold's Gravatar They had joined[url=http://www.game4power.com/]game4power[/url] the humans, elves, dwarves, and [url=http://www.game4power.com/]Buy Wow Gold[/url]dragons to decimate the demonic warriors and ghoulish beasts and push the[url=http://www.aocsale.com]aoc gold[/url] remnants back into [url=http://www.game4power.com/buy-gold/" target="_blank">http://www.game4power.com/buy-gold/]wow gold cheap[/url]the hellish beyond. Thousands [url=http://www.vipwarhammergold.com]warhammer gold[/url]had perished, but the alternative… The dragon mage snorted. In truth, [url=http://www.itemchannel.com]wow gold[/url]there had beenno alternative. Krasus waved [url=http://www.aion4gold.com]aion gold[/url]long, tapering fingers over the orb, summoning a vision of the orcs. The view[url=http://www.itemchannel.com]world of warcraft gold[/url]blurred momentarily, then revealed a mountainous, rocky [url=http://www.ppgold.com]wow gold cheap[/url]area further inland. A harsh land, but one still full of life and capable of [url=http://www.wowgoldone.com/]cheapest wow gold[/url]supporting the new colonists. Already, several stone [url=http://www.wowgoldone.com/][i]cheap wow gold[/i][/url]structures had risen in the main settlement, where the [url=http://www.vipaiongold.com]aion gold[/url]Warchief and one of[url=http://www.aionkina.com]aion kina[/url]the heroes of the war, Thrall, ruled. The high, rounded edifice [url=http://www.game4power.com/]Wow Gold [/url],[url=http://www.game4power.com/]www.game4power.com[/url]that served as his quarters was crude by the standards of any other race, but orcs had a propensity toward basics.
# Posted By buy wow gold | 01/07/09 14:04 | Report abusive comment
BlogCFC was created by Raymond Camden. This blog is running version 5.5.1.