Muokkaa

Jaa


EntityViewGenerator.GenerateViews Method

Definition

Generates views at compile time for the extents in a StorageMappingItemCollection, and creates a source code file that makes these views available at run time.

Overloads

GenerateViews(StorageMappingItemCollection, TextWriter)

Generates views at compile time for the extents in a StorageMappingItemCollection. Sends a source code file to a TextWriter to make these views available at run time.

GenerateViews(StorageMappingItemCollection, String)

Generates views at compile time for the extents in a StorageMappingItemCollection. Writes a source code file to a specified location that makes the views available at run time.

GenerateViews(StorageMappingItemCollection, TextWriter, Version)

Generates views at compile time for the extents in a StorageMappingItemCollection. Sends a source code file to a TextWriter to make these views available at run time.

Remarks

By default, views are generated at run time whenever a query or update is performed on an extent. Generating views at compile time can improve application performance by eliminating the expense of generating views at run time.

GenerateViews(StorageMappingItemCollection, TextWriter)

Important

This API is not CLS-compliant.

Generates views at compile time for the extents in a StorageMappingItemCollection. Sends a source code file to a TextWriter to make these views available at run time.

public:
 System::Collections::Generic::IList<System::Data::Metadata::Edm::EdmSchemaError ^> ^ GenerateViews(System::Data::Mapping::StorageMappingItemCollection ^ mappingCollection, System::IO::TextWriter ^ outputWriter);
public System.Collections.Generic.IList<System.Data.Metadata.Edm.EdmSchemaError> GenerateViews (System.Data.Mapping.StorageMappingItemCollection mappingCollection, System.IO.TextWriter outputWriter);
[System.CLSCompliant(false)]
public System.Collections.Generic.IList<System.Data.Metadata.Edm.EdmSchemaError> GenerateViews (System.Data.Mapping.StorageMappingItemCollection mappingCollection, System.IO.TextWriter outputWriter);
member this.GenerateViews : System.Data.Mapping.StorageMappingItemCollection * System.IO.TextWriter -> System.Collections.Generic.IList<System.Data.Metadata.Edm.EdmSchemaError>
[<System.CLSCompliant(false)>]
member this.GenerateViews : System.Data.Mapping.StorageMappingItemCollection * System.IO.TextWriter -> System.Collections.Generic.IList<System.Data.Metadata.Edm.EdmSchemaError>
Public Function GenerateViews (mappingCollection As StorageMappingItemCollection, outputWriter As TextWriter) As IList(Of EdmSchemaError)

Parameters

mappingCollection
StorageMappingItemCollection

The StorageMappingItemCollection from which views will be generated.

outputWriter
TextWriter

The TextWriter to which the generated code will be sent.

Returns

A list that contains any generated errors.

Attributes

Applies to

GenerateViews(StorageMappingItemCollection, String)

Important

This API is not CLS-compliant.

Generates views at compile time for the extents in a StorageMappingItemCollection. Writes a source code file to a specified location that makes the views available at run time.

public:
 System::Collections::Generic::IList<System::Data::Metadata::Edm::EdmSchemaError ^> ^ GenerateViews(System::Data::Mapping::StorageMappingItemCollection ^ mappingCollection, System::String ^ outputPath);
public System.Collections.Generic.IList<System.Data.Metadata.Edm.EdmSchemaError> GenerateViews (System.Data.Mapping.StorageMappingItemCollection mappingCollection, string outputPath);
[System.CLSCompliant(false)]
public System.Collections.Generic.IList<System.Data.Metadata.Edm.EdmSchemaError> GenerateViews (System.Data.Mapping.StorageMappingItemCollection mappingCollection, string outputPath);
member this.GenerateViews : System.Data.Mapping.StorageMappingItemCollection * string -> System.Collections.Generic.IList<System.Data.Metadata.Edm.EdmSchemaError>
[<System.CLSCompliant(false)>]
member this.GenerateViews : System.Data.Mapping.StorageMappingItemCollection * string -> System.Collections.Generic.IList<System.Data.Metadata.Edm.EdmSchemaError>
Public Function GenerateViews (mappingCollection As StorageMappingItemCollection, outputPath As String) As IList(Of EdmSchemaError)

Parameters

mappingCollection
StorageMappingItemCollection

The StorageMappingItemCollection from which views will be generated.

outputPath
String

The String that specifies the location to which the source code file will be written.

Returns

A list that contains any generated errors.

Attributes

Applies to

GenerateViews(StorageMappingItemCollection, TextWriter, Version)

Important

This API is not CLS-compliant.

Generates views at compile time for the extents in a StorageMappingItemCollection. Sends a source code file to a TextWriter to make these views available at run time.

public:
 System::Collections::Generic::IList<System::Data::Metadata::Edm::EdmSchemaError ^> ^ GenerateViews(System::Data::Mapping::StorageMappingItemCollection ^ mappingCollection, System::IO::TextWriter ^ outputWriter, Version ^ targetEntityFrameworkVersion);
[System.CLSCompliant(false)]
public System.Collections.Generic.IList<System.Data.Metadata.Edm.EdmSchemaError> GenerateViews (System.Data.Mapping.StorageMappingItemCollection mappingCollection, System.IO.TextWriter outputWriter, Version targetEntityFrameworkVersion);
[<System.CLSCompliant(false)>]
member this.GenerateViews : System.Data.Mapping.StorageMappingItemCollection * System.IO.TextWriter * Version -> System.Collections.Generic.IList<System.Data.Metadata.Edm.EdmSchemaError>
Public Function GenerateViews (mappingCollection As StorageMappingItemCollection, outputWriter As TextWriter, targetEntityFrameworkVersion As Version) As IList(Of EdmSchemaError)

Parameters

mappingCollection
StorageMappingItemCollection

The StorageMappingItemCollection to be validated.

outputWriter
TextWriter

The TextWriter to which the output is written.

targetEntityFrameworkVersion
Version

The property of EntityFrameworkVersions that corresponds to the targeted version of the Entity Framework.

Returns

A list that contains any generated errors.

Attributes

Applies to