Login | Register   
LinkedIn
Google+
Twitter
RSS Feed
Download our iPhone app
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   FORUMS  |   TIP BANK
Browse DevX
Sign up for e-mail newsletters from DevX


advertisement
 

Put Modern Code Generation to Work : Page 2

The notion of software that writes software has been around for decades, but it is only recently that developers are taking this notion of code generation seriously. What changed? Code generation changed—and much for the better.


advertisement
Making Code Generation Work Today
Since these various attempts were introduced, a number of things have transpired to make code generation faster, stronger, and smarter than ever before. What's different? In a word: Standards.
  • Architecture: Today, we have a strong notion of what application architecture ought to be. A two-tier architecture for client-server applications and the more contemporary three-tier or n-tier for Web applications. Each tier can be segmented and defined.
  • User Interface: There used to be dozens of standards for the user interface, everything from DOS to the 80-character and 32/70 screen displays, and now of course there are Windows and MAC-based formats. However, for Web applications, we have a common standard: HTML. And every user is guaranteed to have a modern Web browser.
  • Language: The number of programming languages in use is large, but most of our primary corporate application development is done in one of three languages: Visual Basic, C#, or Java.
  • Database: Day-to-day corporate applications are almost exclusively SQL now, notwithstanding some of the modern XQuery XML databases.

With the issues above more or less decided, we've been able to move forward, introducing modern techniques that get us much closer to the dream of code generation.

Modern Code Generation Techniques
Perhaps not surprisingly, the list of modern code generation techniques reads a little bit like an the "outdated" code generators mentioned earlier, with different names. Sort of like bell-bottoms and leisure suits; they keep coming back to haunt us in new fabrics.



For instance, the MDAUML (Model Driven Architecture / Universal Modeling Language) approaches create a scenario like the CASE tools: UML works very well in shops that have an almost religious conviction about the application planning and development process. However, they don't work well for most of us. We like to sit down with our customers, whether internal or external, and show them screens right away. We want to toss stuff up there and iterate from the feedback we receive.

Another take on the component libraries is the Enterprise Templates feature found in Visual Studio.NET. These templates are planning and design modules that allow you, among other things, to build code snippets in the IDE itself so it can be shared across a number of applications.

Many of you may have done the same thing by building your own code generators. There is a great Web site called www.codegeneration.net (operated by DevX author Jack D. Herrington) that has a large user forum on building your own code generator. Again, if you find that you are building the same portions of applications over and over again, it may behoove you to construct a single-purpose code generator.

Declarative code generators are a new class of code generators that really do deliver on the promise of generating your application, not just portions of it. Declarative generators work by allowing you to simply state what it is that you want, rather than modeling it out. They are particularly suited to the iterative style of development. And let's face it: Right or wrong, this iterative approach is what we use in practice.



Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

Sitemap
Thanks for your registration, follow us on our social networks to keep up-to-date