O'Reilly logo

Entity Framework 4 in Action by Daniele Bochicchio, Marco De Sanctis, Stefano Mostarda

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 13. Customizing code and the designer

 

This chapter covers
  • Understanding the Visual Studio T4 mechanism
  • Customizing code generation
  • Customizing database DDL generation
  • Customizing the designer

 

You know that by default the Visual Studio designer generates Entity Framework 1.0–style classes. You also know that these classes are generated through a template. What’s great is that you can modify this template, or create new templates, to generate classes to fit your needs. You’ve already seen an example in chapter 2, when we introduced the POCO template provided by Microsoft. Another point where templates help in generating code is during database DDL generation from the storage model (when you use the model-first approach). You’ll ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required