CodeSmith Community
Your Code. Your Way. Faster!
Using LINQ with SchemaExplorer in CodeSmith 5.1

SchemaExplorer now contains the LINQ to easier querying of metadata!

A new feature in CodeSmith 5.1 is the ability to use LINQ with SchemaExplorer.  LINQ support makes it easier to filter, organize and sort the metadata from your datasource. 

Here is a quick sample that shows the difference LINQ makes in developing a CodeSmith template:

Before

After

As you can see, LINQ will make your templates easier to read and a lot easier to maintain.  This sample is attached so you can try it yourself.  Also, to demonstrate LINQ with SchemaExplorer, we have updated the StoreProcedures template that ships with CodeSmith 5.1 to take advantage of the LINQ support.  The StoredProcedures template is located in the Database\StoredProcedures samples folder.

With LINQ support in SchemaExplorer, it is much easier and cleaner to get the data you want when generating code using CodeSmith.


Posted 04-19-2009 12:45 PM by shannon
Filed under:
Copyright © 2008 CodeSmith Tools, LLC
Powered by Community Server (Commercial Edition), by Telligent Systems