Project DescriptionEF4 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 StartedThe 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