<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>How to use a T4 template for View Generation</title><link>http://blogs.msdn.com/adonet/archive/2008/06/20/how-to-use-a-t4-template-for-view-generation.aspx</link><description>Background To set the stage for this article, do take a look at Exploring the Performance of the ADO.NET Entity Framework - Part 1 to learn more about pre-generating views and how they can reduce the startup time for applications that consume ADO.NET</description><dc:language>en</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>Pregnant Man &amp;raquo; How to use a T4 template for View Generation</title><link>http://blogs.msdn.com/adonet/archive/2008/06/20/how-to-use-a-t4-template-for-view-generation.aspx#8626708</link><pubDate>Fri, 20 Jun 2008 22:41:02 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8626708</guid><dc:creator>Pregnant Man &amp;raquo; How to use a T4 template for View Generation</dc:creator><description>&lt;p&gt;PingBack from &lt;a rel="nofollow" target="_new" href="http://wordnew.acne-reveiw.info/?p=973"&gt;http://wordnew.acne-reveiw.info/?p=973&lt;/a&gt;&lt;/p&gt;
</description></item><item><title>re: How to use a T4 template for View Generation</title><link>http://blogs.msdn.com/adonet/archive/2008/06/20/how-to-use-a-t4-template-for-view-generation.aspx#8641796</link><pubDate>Mon, 23 Jun 2008 13:41:44 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8641796</guid><dc:creator>Thaabiet</dc:creator><description>&lt;p&gt;Hi. I've followed the above procedure but get the following error: Compiling transformation: Argument '1': cannot convert from 'System.Xml.XmlReader[]' to 'System.Data.Common.DbConnection'	c:\Dev\RAMBillingWeb\DataAccess\RAMBilling.DAL\Repository\RAMBillingEDM.Views.tt	105&lt;/p&gt;
</description></item><item><title>T4 (Text Template Transformation Toolkit) Code Generation - Best Kept Visual Studio Secret</title><link>http://blogs.msdn.com/adonet/archive/2008/06/20/how-to-use-a-t4-template-for-view-generation.aspx#9000002</link><pubDate>Tue, 14 Oct 2008 23:09:16 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9000002</guid><dc:creator>ASPInsiders</dc:creator><description>&lt;p&gt;Rob beat me to it . Blogging about T4 (the Text Template Transformation Toolkit ) had been on my list&lt;/p&gt;
</description></item><item><title>New T4 "How Do I?"-Videos , new T4 Editor and Online T4 Template Gallery</title><link>http://blogs.msdn.com/adonet/archive/2008/06/20/how-to-use-a-t4-template-for-view-generation.aspx#9575267</link><pubDate>Wed, 29 Apr 2009 11:08:38 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9575267</guid><dc:creator>Tim Fischer's .NET Small and Medium App Blog</dc:creator><description>&lt;p&gt;As Jean Marc and Oleg pointed out T4 is getting more attention now. Tangible Engineering did now post&lt;/p&gt;
</description></item><item><title>Recent blog posts about T4</title><link>http://blogs.msdn.com/adonet/archive/2008/06/20/how-to-use-a-t4-template-for-view-generation.aspx#9701166</link><pubDate>Fri, 05 Jun 2009 14:06:42 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9701166</guid><dc:creator>VS2010学习</dc:creator><description>&lt;p&gt;I came across several blog posts about T4 code generation you may find useful. Sanjay Nagamangalam posted&lt;/p&gt;
</description></item><item><title>re: How to use a T4 template for View Generation</title><link>http://blogs.msdn.com/adonet/archive/2008/06/20/how-to-use-a-t4-template-for-view-generation.aspx#9839570</link><pubDate>Sun, 19 Jul 2009 08:27:24 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9839570</guid><dc:creator>Muthuraj</dc:creator><description>&lt;p&gt;We are using ADO.NET Entity for our ASP.NET application.&lt;/p&gt;
&lt;p&gt;I have read that the pre-generated views improves the performance. Referred to this blog post, &lt;/p&gt;
&lt;p&gt;I generated the views. The namespace &amp;amp; classes generated as&lt;/p&gt;
&lt;p&gt;namespace Edm_EntityMappingGeneratedViews&lt;/p&gt;
&lt;p&gt;{&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;/// &amp;lt;Summary&amp;gt;&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;/// The type contains views for EntitySets and AssociationSets that were generated at design time.&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;/// &amp;lt;/Summary&amp;gt;&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;public sealed class ViewsForBaseEntitySets4D4A6E0AA7AF6B2298FABB4F22235831 : System.Data.Mapping.EntityViewContainer&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;{&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;/// &amp;lt;Summary&amp;gt;&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;/// The constructor stores the views for the extents and also the hash values generated based on the metadata and mapping closure and views&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;/// &amp;lt;/Summary&amp;gt;&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;public ViewsForBaseEntitySets4D4A6E0AA7AF6B2298FABB4F22235831()&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;{&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;this.EdmEntityContainerName = &amp;quot;JSEntities&amp;quot;;&lt;/p&gt;
&lt;p&gt;I added this to my data layer and test the performance. Couldn't see much improvement. CPU usage always goes to 20-30% utilization (response timing is good) and reduce back to 0% in 500ms - 1 sec. I think the CPU utilization goes high because of view generation every time.&lt;/p&gt;
&lt;p&gt;I couldn't understand how the entity framework knows that this is my pre-generated view class for my model eventhough the MyModel.edmx &amp;amp; MyModel.Views.cs matches with filename.&lt;/p&gt;
&lt;p&gt;Should I have to update Web.Config or App.Config to map the View class to model somewhere?&lt;/p&gt;
&lt;p&gt;Please clarify.&lt;/p&gt;
</description></item><item><title>re: How to use a T4 template for View Generation</title><link>http://blogs.msdn.com/adonet/archive/2008/06/20/how-to-use-a-t4-template-for-view-generation.aspx#9846218</link><pubDate>Thu, 23 Jul 2009 15:44:38 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9846218</guid><dc:creator>Seba</dc:creator><description>&lt;p&gt;I am having the same problem as Thaabiet.&lt;/p&gt;
&lt;p&gt;I am getting the same error, please any help would be appreciated&lt;/p&gt;
</description></item><item><title>re: How to use a T4 template for View Generation</title><link>http://blogs.msdn.com/adonet/archive/2008/06/20/how-to-use-a-t4-template-for-view-generation.aspx#9846477</link><pubDate>Thu, 23 Jul 2009 18:24:45 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9846477</guid><dc:creator>Seba</dc:creator><description>&lt;p&gt;now I am facing Muthuraj issue.&lt;/p&gt;
&lt;p&gt;I don't see any performance improvements and don't see where is set to read model.view.cs insted of edex. Any help on this thanks&lt;/p&gt;
</description></item><item><title>re: How to use a T4 template for View Generation</title><link>http://blogs.msdn.com/adonet/archive/2008/06/20/how-to-use-a-t4-template-for-view-generation.aspx#9912359</link><pubDate>Sat, 24 Oct 2009 02:34:33 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9912359</guid><dc:creator>James</dc:creator><description>&lt;p&gt;Thanks for the tip. &amp;nbsp;This worked well to eliminate a 45 second startup load time in an EDMX model in which one of our tables contained 27 foreign keys to other tables.&lt;/p&gt;
</description></item></channel></rss>