Share via


Extending the Entity Data Model Tools

You can extend the functionality of the ADO.NET Entity Data Model Tools by using classes in the Microsoft.Data.Entity.Design.Extensibility namespace to write Visual Studio extensions. Classes in the Microsoft.Data.Entity.Design.Extensibility namespace allow you to do the following actions:

NoteNote

For code examples of the following extensions, see the ADO.NET Entity Data Model Designer Extension Starter Kit.

The functionality described above can be combined in one Visual Studio extension. For example, you could load a .uml file by using the OnAfterFileLoaded method (which will convert the file to an .edmx format), then modify the .edmx file with the OnAfterModelLoaded method before it is displayed in the Entity Designer. Conversely, you could modify a loaded .edmx file with the OnBeforeModelSaved method, then convert it to a .uml file with the OnBeforeFileSaved method before it is saved.

Also note that multiple implementations of the extension interfaces can be implemented in the same Visual Studio extension. For example, multiple implementations of the IModelTransformExtension interface could, in turn, make modifications to an .edmx file before it is displayed in the Entity Designer or before it is saved.

For information about writing Visual Studio extensions, see Developing Visual Studio Extensions and Managed Extensibility Framework (MEF).

For information about customizing other functionality of the Entity Data Model Tools, see How to: Customize Object-Layer Code Generation and How to: Customize Database Generation.

In This Section

See Also

Other Resources

ADO.NET Entity Data Model Tools