Tech Embassy

Sunday, January 08, 2006

Double Automated Power

Microsoft developed an extension to Visual Studio 2005 called Guidance Automation Toolkit (GAT).
GAT generates new visual studio projects with auto generated code, so it is combination of VS project templates with code generation.

GAT = Code Generation + VS Project Templates


Let's suppose that we want to build a new application with 3 tiers, DAL, BLL and UI
We need to create three new projects, both are class libraries and one is windows application.
And let's suppose that we are doing that over and over with all our applications.

With GAT we can build a project template in VS, and register it.
The new template will be displayed in the "New Project" dialog box in VS as an option of project type.
By choosing this template, VS will create 3 projects and write optional code as well.

building user-defined project templates in VS is not new at all, and existed with VS 2003, but the new about GAT, that it combines that with code generation, and allows to build an interface that allows the user to enter parameters for the code generation templates

I am big fan of Code Generation, and I created some code generation templates with Code Smith and I was thinking to mix the code smith templates with Visual Studio Project Templates, but didn't spend time to figure out how to call Code Smith UI (which allows the user to enter the parameters value) from VS.

GAT is a toolkit to write VS project templates and Code generation templates
As well you can build UI to enter any parameters for the code generation

It doesn't have the same rich functionalities of Code Smith, but I am sure soon, some third-party add-ins will add to the GAT to give it more funcitonality, or maybe Codesmith will cooperate with VS to include their code generation engine in GAT

0 Comments:

Post a Comment

<< Home