Share via


CompilationOptions 類別

定義

表示 C# 和 VB 通用的編譯選項。

public ref class CompilationOptions abstract
public abstract class CompilationOptions
type CompilationOptions = class
Public MustInherit Class CompilationOptions
繼承
CompilationOptions
衍生

屬性

AssemblyIdentityComparer

用來比較元件識別。 可以實作目標平臺特定的統一和可攜性原則。 Default 如果未指定,則為 。

CheckOverflow

是否預設會強制執行整數算術上的界限檢查。

ConcurrentBuild

指定建置編譯是否可以使用多個執行緒。

CryptoKeyContainer

CSP 容器,其中包含用來簽署輸出的金鑰。

CryptoKeyFile

包含公開金鑰和私密金鑰的檔案名,用來產生編譯元件的強式名稱並簽署它。

CryptoPublicKey

指定用來產生編譯元件的強式名稱的公開金鑰,如果未指定則為空白。

DelaySign

將編譯元件標示為延遲簽署。

Deterministic

指定編譯是否應該具決定性。

Errors

與一組不相容編譯選項相關的錯誤集合

Features
已淘汰.

一組字串,指定要啟用的實驗性編譯器功能。

GeneralDiagnosticOption

全域警告報告選項

Language

取得來來源語言 (「C#」 或 「Visual Basic」) 。

MainTypeName

宣告靜態 Main 方法之型別的完整名稱。 必須是有效的非泛型命名空間限定名稱。 如果有任何靜態 Main 方法是進入點的候選項目,則為 Null。

MetadataImportOptions

指定是否要匯入具有公用或預設保護之協助工具的成員。 預設值為 Public。 指定的值不會影響編譯器所執行之分析的正確性,因為不論匯入正確性所需的所有成員都會匯入。 此設定可以強制編譯以匯入通常不會匯入的成員。

MetadataReferenceResolver

透過 #r 指示詞解析來源中指定的中繼資料參考路徑。 如果編譯不能包含明確傳遞給其處理站 (以外的中繼資料參考,例如來源) 中的#r指示詞,則為 Null。

ModuleName

主要模組的名稱,如果應該使用預設名稱,則為 null。

NullableContextOptions

取得這個編譯中預設可為 Null 的內容狀態。

OptimizationLevel

指定是否應在輸出 IL 上執行優化。 這與是否產生 PDB 資訊無關。

OutputKind

發出時產生的元件種類。

Platform

指定哪個 Common Language Runtime (CLR) 版本可以執行組件。

PublicSign

將編譯元件標示為完整簽署,但只使用公開金鑰簽署。

ReportSuppressedDiagnostics

是否應該報告來源中隱藏的診斷,也就是 IsSuppressed true。

ScriptClassName

全域隱含類別的完整名稱 (腳本類別) 。 這個類別會隱含地封裝最上層語句、類型宣告和成員宣告。 可以是命名空間限定名稱。

SourceReferenceResolver

取得解析編譯來源文件參考的解析程式。 如果不允許編譯包含原始程式檔參考,例如 #line pragmas 和 #load 指示詞,則為 Null。

SpecificDiagnosticOptions

每個警告的警告報告選項。

StrongNameProvider

提供來源元件的強式名稱與簽章。 如果不支援元件簽署,則為 Null。

SyntaxTreeOptionsProvider

用來擷取特定語法樹狀架構選項的提供者。

WarningLevel

全域警告層級 (非負整數) 。

XmlReferenceResolver

取得解析編譯之 XML 檔參考的解析程式。 如果不允許編譯包含 XML 檔案參考,例如 XML 檔批註包含儲存在 XML 檔案中的標記和許可權集合,則為 Null。

方法

CommonWithAssemblyIdentityComparer(AssemblyIdentityComparer)

表示 C# 和 VB 通用的編譯選項。

CommonWithCheckOverflow(Boolean)

表示 C# 和 VB 通用的編譯選項。

CommonWithConcurrentBuild(Boolean)

表示 C# 和 VB 通用的編譯選項。

CommonWithCryptoKeyContainer(String)

表示 C# 和 VB 通用的編譯選項。

CommonWithCryptoKeyFile(String)

表示 C# 和 VB 通用的編譯選項。

CommonWithCryptoPublicKey(ImmutableArray<Byte>)

表示 C# 和 VB 通用的編譯選項。

CommonWithDelaySign(Nullable<Boolean>)

表示 C# 和 VB 通用的編譯選項。

CommonWithDeterministic(Boolean)

表示 C# 和 VB 通用的編譯選項。

CommonWithFeatures(ImmutableArray<String>)
已淘汰.

表示 C# 和 VB 通用的編譯選項。

CommonWithGeneralDiagnosticOption(ReportDiagnostic)

表示 C# 和 VB 通用的編譯選項。

CommonWithMainTypeName(String)

表示 C# 和 VB 通用的編譯選項。

CommonWithMetadataImportOptions(MetadataImportOptions)

表示 C# 和 VB 通用的編譯選項。

CommonWithMetadataReferenceResolver(MetadataReferenceResolver)

表示 C# 和 VB 通用的編譯選項。

CommonWithModuleName(String)

表示 C# 和 VB 通用的編譯選項。

CommonWithOptimizationLevel(OptimizationLevel)

表示 C# 和 VB 通用的編譯選項。

CommonWithOutputKind(OutputKind)

表示 C# 和 VB 通用的編譯選項。

CommonWithPlatform(Platform)

表示 C# 和 VB 通用的編譯選項。

CommonWithPublicSign(Boolean)

表示 C# 和 VB 通用的編譯選項。

CommonWithReportSuppressedDiagnostics(Boolean)

表示 C# 和 VB 通用的編譯選項。

CommonWithScriptClassName(String)

表示 C# 和 VB 通用的編譯選項。

CommonWithSourceReferenceResolver(SourceReferenceResolver)

表示 C# 和 VB 通用的編譯選項。

CommonWithSpecificDiagnosticOptions(IEnumerable<KeyValuePair<String,ReportDiagnostic>>)

表示 C# 和 VB 通用的編譯選項。

CommonWithSpecificDiagnosticOptions(ImmutableDictionary<String,ReportDiagnostic>)

表示 C# 和 VB 通用的編譯選項。

CommonWithStrongNameProvider(StrongNameProvider)

表示 C# 和 VB 通用的編譯選項。

CommonWithSyntaxTreeOptionsProvider(SyntaxTreeOptionsProvider)

表示 C# 和 VB 通用的編譯選項。

CommonWithXmlReferenceResolver(XmlReferenceResolver)

表示 C# 和 VB 通用的編譯選項。

ComputeHashCode()

表示 C# 和 VB 通用的編譯選項。

Equals(Object)

表示 C# 和 VB 通用的編譯選項。

EqualsHelper(CompilationOptions)

表示 C# 和 VB 通用的編譯選項。

GetHashCode()

表示 C# 和 VB 通用的編譯選項。

GetHashCodeHelper()

表示 C# 和 VB 通用的編譯選項。

WithAssemblyIdentityComparer(AssemblyIdentityComparer)

表示 C# 和 VB 通用的編譯選項。

WithConcurrentBuild(Boolean)

建立新的選項實例,並據此設定並行建置屬性。

WithCryptoKeyContainer(String)

表示 C# 和 VB 通用的編譯選項。

WithCryptoKeyFile(String)

表示 C# 和 VB 通用的編譯選項。

WithCryptoPublicKey(ImmutableArray<Byte>)

表示 C# 和 VB 通用的編譯選項。

WithDelaySign(Nullable<Boolean>)

表示 C# 和 VB 通用的編譯選項。

WithDeterministic(Boolean)

建立新的選項實例,並據此設定具決定性屬性。

WithGeneralDiagnosticOption(ReportDiagnostic)

使用指定的一般診斷選項建立新的選項實例。

WithMainTypeName(String)

表示 C# 和 VB 通用的編譯選項。

WithMetadataImportOptions(MetadataImportOptions)

表示 C# 和 VB 通用的編譯選項。

WithMetadataReferenceResolver(MetadataReferenceResolver)

表示 C# 和 VB 通用的編譯選項。

WithModuleName(String)

表示 C# 和 VB 通用的編譯選項。

WithOptimizationLevel(OptimizationLevel)

建立已啟用或停用優化的新選項實例。

WithOutputKind(OutputKind)

使用指定的輸出種類建立新的選項實例。

WithOverflowChecks(Boolean)

表示 C# 和 VB 通用的編譯選項。

WithPlatform(Platform)

使用指定的平臺建立新的選項實例。

WithPublicSign(Boolean)

使用指定的公用簽署設定,建立新的選項實例。

WithReportSuppressedDiagnostics(Boolean)

使用指定的隱藏診斷報告選項,建立新的選項實例。

WithScriptClassName(String)

表示 C# 和 VB 通用的編譯選項。

WithSourceReferenceResolver(SourceReferenceResolver)

表示 C# 和 VB 通用的編譯選項。

WithSpecificDiagnosticOptions(IEnumerable<KeyValuePair<String,ReportDiagnostic>>)

使用指定的診斷特定選項建立新的選項實例。

WithSpecificDiagnosticOptions(ImmutableDictionary<String,ReportDiagnostic>)

使用指定的診斷特定選項建立新的選項實例。

WithStrongNameProvider(StrongNameProvider)

表示 C# 和 VB 通用的編譯選項。

WithSyntaxTreeOptionsProvider(SyntaxTreeOptionsProvider)

表示 C# 和 VB 通用的編譯選項。

WithXmlReferenceResolver(XmlReferenceResolver)

表示 C# 和 VB 通用的編譯選項。

運算子

Equality(CompilationOptions, CompilationOptions)

表示 C# 和 VB 通用的編譯選項。

Inequality(CompilationOptions, CompilationOptions)

表示 C# 和 VB 通用的編譯選項。

適用於