EntityViewGenerator.GenerateViews 方法

定義

在編譯時為 中的 區間 StorageMappingItemCollection產生檢視,並建立原始碼檔案,使這些檢視在執行時可用。

多載

名稱 Description
GenerateViews(StorageMappingItemCollection, TextWriter)

在編譯時 StorageMappingItemCollection產生 . 傳送原始碼檔案到 a TextWriter ,讓這些視圖在執行時可用。

GenerateViews(StorageMappingItemCollection, String)

在編譯時 StorageMappingItemCollection產生 . 將原始碼檔案寫入指定位置,讓檢視在執行時可用。

GenerateViews(StorageMappingItemCollection, TextWriter, Version)

在編譯時 StorageMappingItemCollection產生 . 傳送原始碼檔案到 a TextWriter ,讓這些視圖在執行時可用。

備註

預設情況下,當對某個區域執行查詢或更新時,視圖會在執行時產生。 在編譯時產生檢視,能透過消除執行時產生檢視的成本,提升應用程式效能。

GenerateViews(StorageMappingItemCollection, TextWriter)

重要

此 API 不符合 CLS 規範。

在編譯時 StorageMappingItemCollection產生 . 傳送原始碼檔案到 a TextWriter ,讓這些視圖在執行時可用。

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)

參數

mappingCollection
StorageMappingItemCollection

StorageMappingItemCollection這些資訊將產生觀看。

outputWriter
TextWriter

TextWriter生成的程式碼會被傳送到那裡。

傳回

一個包含所有產生錯誤的清單。

屬性

適用於

GenerateViews(StorageMappingItemCollection, String)

重要

此 API 不符合 CLS 規範。

在編譯時 StorageMappingItemCollection產生 . 將原始碼檔案寫入指定位置,讓檢視在執行時可用。

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)

參數

mappingCollection
StorageMappingItemCollection

StorageMappingItemCollection這些資訊將產生觀看。

outputPath
String

String 就是指定原始碼檔案要寫入的位置。

傳回

一個包含所有產生錯誤的清單。

屬性

適用於

GenerateViews(StorageMappingItemCollection, TextWriter, Version)

重要

此 API 不符合 CLS 規範。

在編譯時 StorageMappingItemCollection產生 . 傳送原始碼檔案到 a TextWriter ,讓這些視圖在執行時可用。

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)

參數

outputWriter
TextWriter

TextWriter輸出被寫入的

targetEntityFrameworkVersion
Version

該屬性 EntityFrameworkVersions 對應於實體框架的目標版本。

傳回

一個包含所有產生錯誤的清單。

屬性

適用於