EdmxWriter.WriteEdmx Method

Definition

Overloads

WriteEdmx(DbContext, XmlWriter)

Uses Code First with the given context and writes the resulting Entity Data Model to the given writer in EDMX form. This method can only be used with context instances that use Code First and create the model internally. The method cannot be used for contexts created using Database First or Model First, for contexts created using a pre-existing ObjectContext, or for contexts created using a pre-existing DbCompiledModel.

WriteEdmx(DbModel, XmlWriter)

Writes the Entity Data Model represented by the given DbModel to the given writer in EDMX form.

WriteEdmx(DbContext, XmlWriter)

Uses Code First with the given context and writes the resulting Entity Data Model to the given writer in EDMX form. This method can only be used with context instances that use Code First and create the model internally. The method cannot be used for contexts created using Database First or Model First, for contexts created using a pre-existing ObjectContext, or for contexts created using a pre-existing DbCompiledModel.

[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId="Edmx")]
public static void WriteEdmx (System.Data.Entity.DbContext context, System.Xml.XmlWriter writer);
public static void WriteEdmx (System.Data.Entity.DbContext context, System.Xml.XmlWriter writer);
static member WriteEdmx : System.Data.Entity.DbContext * System.Xml.XmlWriter -> unit
Public Shared Sub WriteEdmx (context As DbContext, writer As XmlWriter)

Parameters

context
DbContext

The context.

writer
XmlWriter

The writer.

Attributes

Applies to

WriteEdmx(DbModel, XmlWriter)

Writes the Entity Data Model represented by the given DbModel to the given writer in EDMX form.

[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId="Edmx")]
public static void WriteEdmx (System.Data.Entity.Infrastructure.DbModel model, System.Xml.XmlWriter writer);
public static void WriteEdmx (System.Data.Entity.Infrastructure.DbModel model, System.Xml.XmlWriter writer);
static member WriteEdmx : System.Data.Entity.Infrastructure.DbModel * System.Xml.XmlWriter -> unit
Public Shared Sub WriteEdmx (model As DbModel, writer As XmlWriter)

Parameters

model
DbModel

An object representing the EDM.

writer
XmlWriter

The writer.

Attributes

Applies to