Search
Project Description
EF4 Templates uses T4toolbox to generate Repositories, Unit of work, POCO self-tracking entities that can be unit tested, along with validation for WPF, Silverlight RIA services and ASP.NET/ASP.NET MVC. They also generate an ODATA service with authentication for usage with WPF.

Now on Nuget! Type "Install-Package EF4Templates"

Getting Started

The POCO self-tracking entities in here are the same as the ones in the online gallery with a few key features added:
  • Xml documentation
  • Field names are camel-case parsed to real text with <DisplayName("Name")> using DataAnnotations.
  • Uses T4Toolbox to generate files that are attached in the project and not below the T4 file.

Features already implemented:
  • Repository with unit-tests and unit of work implementation.
  • Self-tracking entities that use IContext and IObjectSet so they can be seperated from EF, and unit tested.
  • Fake object context for testing purposes.
  • OData service endpoint for use with WPF or windows forms, including forms authentication.
  • Validation using sidecar classes like RIA services with System.ComponentModel.DataAnnotiations. A special class is generated for WPF to use System.ComponentModel.DataAnnotations too.
  • XML documentation for use with SandCastle.
  • Unit tests for the repository and FakeObjectSet
  • Optional exclusion of generated classes from code coverage (except classes with unit tests)

The templates generate VB.NET and C# code too. Wanna help?

Special thanks to Julie Lerman for guidance, and a great book http://my.safaribooksonline.com/9780596807276 !

Follow me on twitter @RickRat http://twitter.com/rickrat
Last edited Apr 21 2011 at 5:44 AM by rickrat, version 34
Updating...
© 2006-2012 Microsoft | Get Help | Privacy Statement | Terms of Use | Code of Conduct | Advertise With Us | Version 2012.1.11.18365