BuildProviderAppliesTo 列舉

定義

指定 BuildProviderAppliesToAttribute 物件產生資源的程式碼時,BuildProvider 屬性被承認的位置。Specifies the locations where the BuildProviderAppliesToAttribute attribute is respected during code generation for a resource by a BuildProvider object.

此列舉具有 FlagsAttribute 個屬性允許以位元方式合併其成員值。

public enum class BuildProviderAppliesTo
[System.Flags]
public enum BuildProviderAppliesTo
type BuildProviderAppliesTo = 
Public Enum BuildProviderAppliesTo
繼承
BuildProviderAppliesTo
屬性

欄位

All 7

指定在找到資源時,組建提供者都會產生資源的程式碼。Specifies that the build provider generates code for resources wherever the resources are found. 這是 BuildProviderAppliesToAttribute 屬性的預設值。This is the default value for the BuildProviderAppliesToAttribute attribute.

Code 2

指定資源位於 \App_Code 目錄時,組建提供者才會產生程式碼。Specifies that the build provider generates code for only those resources in the \App_Code directory.

Resources 4

指定組建提供者為 \App_GlobalResources 和 \App_LocalResources 目錄中的資源產生程式碼。Specifies that the build provider generates code for resources in the \App_GlobalResources and \App_LocalResources directories.

Web 1

指定組建提供者只為 Web 內容目錄 (ASP.NET 保留目錄 \App_Code、\App_GlobalResources 和 \App_LocalResources 之外的目錄) 中的資源產生程式碼。Specifies that the build provider generates code for only those resources in Web content directories, which are directories other than the reserved ASP.NET directories \App_Code, \App_GlobalResources, and \App_LocalResources.

備註

BuildProvider物件提供在資源編譯期間剖析特定檔案類型和產生程式碼的功能。A BuildProvider object provides functionality to parse a particular file type and generate code during compilation of a resource. 組建提供者會針對那些對應至BuildProviderAppliesToAttribute屬性的資源產生程式碼, 並將此延伸模組對應至組建提供者。A build provider generates code for those resources that correspond to the BuildProviderAppliesToAttribute attribute and which have the extension mapped to the build provider.

適用於

另請參閱