Action in the Code Generation World

      No Comments on Action in the Code Generation World

Code Generation Network:

".NET developers are just starting to realize the abstraction and productivity benefits of code generation. We have interviews with the industry leaders developing new cutting edge tools for .NET code generation, as well as books and articles that cover the topic, in this special section on Windows and .NET code generation."

I’m not very familiar with code generation but it’s my understanding its main problem is, what happens once the code has been generated. Is it easy to read, can you evolve it by hand, then re-generate parts of it? Seems things are getting better in the Microsoft environment, but then, compared to Visual Interdev, the only way was up (who ever used that tool for anything but prototypes or lousy Intranet stuff?). When you look at the amount of time spent by developers doing basic plumbing on web sites (typically reading from or writing to a database), there’s room for huge productivity gains.
This is 2004 and there are still people releasing new sites in "traditional" ASP or PHP code mixing code and HTML and duplicating almost similar code on every page (I should know about the evils of such ways, I need to refactor one of my sites, which will involve a migration to VB.NET, some amount of page templating, and CSS). And I bet some of these sites loop through live recordsets instead of loading stored procedures into arrays to release the database connection as soon as possible.
In other words, what was OK in 1999 (though really, looping through a live recordset has always been a sloppy shortcut for the lazy) is a sin five years later save for the most trivial projects. The bottom line is, many of the lousy sites you run into (the ones that time out when you were going to complete that long form or order) could be improved with better code rather than more powerful hardware.
If coding tools, including code generating software, indeed reduce the amount of repetitive code and help enforce best practices, the business benefit is significant: more performance and stability in less time for less money. Once developers have gone through the learning curve and get rid of their bad habits of course. But looking at DeKlarit’s demo really impresses me. And I need to make myself familiar with object-relational persistence. And by the way, there’s a difference between simple Data Access Layer (DAL) generators, Object-Relational (O/R) mapping tools, and Object Role Modelling (ORM).
03/11/04 update: Objectspaces will limit interest in O/R mapping (posted by the guy behind LLBLGen Pro).

Leave a Reply

Your email address will not be published. Required fields are marked *