AssemblyCatalog 建構函式
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
初始化 AssemblyCatalog 類別的新執行個體。
多載
| 名稱 | Description |
|---|---|
| AssemblyCatalog(Assembly) |
初始化該類別的新實例 AssemblyCatalog ,使用指定的組合語言。 |
| AssemblyCatalog(String) |
初始化一個以指定程式碼庫為類別的新實例 AssemblyCatalog 。 |
| AssemblyCatalog(Assembly, ICompositionElement) |
初始化該類別的新實例 AssemblyCatalog ,使用指定的組合語言。 |
| AssemblyCatalog(Assembly, ReflectionContext) |
初始化一個以指定的組合語言與反射上下文的新類別實例 AssemblyCatalog 。 |
| AssemblyCatalog(String, ICompositionElement) |
初始化一個以指定程式碼庫為類別的新實例 AssemblyCatalog 。 |
| AssemblyCatalog(String, ReflectionContext) |
初始化一個以指定的程式碼庫和反射上下文的新類別實例 AssemblyCatalog 。 |
| AssemblyCatalog(Assembly, ReflectionContext, ICompositionElement) |
初始化一個以指定的組合語言與反射上下文的新類別實例 AssemblyCatalog 。 |
| AssemblyCatalog(String, ReflectionContext, ICompositionElement) |
初始化一個以指定的程式碼庫和反射上下文的新類別實例 AssemblyCatalog 。 |
AssemblyCatalog(Assembly)
初始化該類別的新實例 AssemblyCatalog ,使用指定的組合語言。
public:
AssemblyCatalog(System::Reflection::Assembly ^ assembly);
public AssemblyCatalog(System.Reflection.Assembly assembly);
new System.ComponentModel.Composition.Hosting.AssemblyCatalog : System.Reflection.Assembly -> System.ComponentModel.Composition.Hosting.AssemblyCatalog
Public Sub New (assembly As Assembly)
參數
- assembly
- Assembly
包含 Type 要加入 AssemblyCatalog 物件的屬性物件的組合語言。
例外狀況
適用於
AssemblyCatalog(String)
初始化一個以指定程式碼庫為類別的新實例 AssemblyCatalog 。
public:
AssemblyCatalog(System::String ^ codeBase);
public AssemblyCatalog(string codeBase);
new System.ComponentModel.Composition.Hosting.AssemblyCatalog : string -> System.ComponentModel.Composition.Hosting.AssemblyCatalog
Public Sub New (codeBase As String)
參數
- codeBase
- String
一個字串,指定組合語言的程式碼基底(即通往組合語言檔案的路徑),其中包含要加入AssemblyCatalog物件的屬性Type物件。
例外狀況
呼叫者沒有路徑發現權限。
codeBase 是 null。
找不到 codeBase。
codeBase 是零長度字串,僅包含空白,或包含一個或多個無效字元,定義如下 InvalidPathChars。
指定的路徑、檔名或兩者都超過系統定義的最大長度。
備註
所參考的 codeBase 組裝體會被載入到載入上下文中。
適用於
AssemblyCatalog(Assembly, ICompositionElement)
初始化該類別的新實例 AssemblyCatalog ,使用指定的組合語言。
public:
AssemblyCatalog(System::Reflection::Assembly ^ assembly, System::ComponentModel::Composition::Primitives::ICompositionElement ^ definitionOrigin);
public AssemblyCatalog(System.Reflection.Assembly assembly, System.ComponentModel.Composition.Primitives.ICompositionElement definitionOrigin);
new System.ComponentModel.Composition.Hosting.AssemblyCatalog : System.Reflection.Assembly * System.ComponentModel.Composition.Primitives.ICompositionElement -> System.ComponentModel.Composition.Hosting.AssemblyCatalog
Public Sub New (assembly As Assembly, definitionOrigin As ICompositionElement)
參數
- assembly
- Assembly
包含 Type 要加入 AssemblyCatalog 物件的屬性物件的組合語言。
- definitionOrigin
- ICompositionElement
診斷用來辨識零件來源的元件。
例外狀況
適用於
AssemblyCatalog(Assembly, ReflectionContext)
初始化一個以指定的組合語言與反射上下文的新類別實例 AssemblyCatalog 。
public:
AssemblyCatalog(System::Reflection::Assembly ^ assembly, System::Reflection::ReflectionContext ^ reflectionContext);
public AssemblyCatalog(System.Reflection.Assembly assembly, System.Reflection.ReflectionContext reflectionContext);
new System.ComponentModel.Composition.Hosting.AssemblyCatalog : System.Reflection.Assembly * System.Reflection.ReflectionContext -> System.ComponentModel.Composition.Hosting.AssemblyCatalog
Public Sub New (assembly As Assembly, reflectionContext As ReflectionContext)
參數
- assembly
- Assembly
包含 Type 要加入 AssemblyCatalog 物件的屬性物件的組合語言。
- reflectionContext
- ReflectionContext
目錄用來解釋類型時所使用的脈絡。
例外狀況
適用於
AssemblyCatalog(String, ICompositionElement)
初始化一個以指定程式碼庫為類別的新實例 AssemblyCatalog 。
public:
AssemblyCatalog(System::String ^ codeBase, System::ComponentModel::Composition::Primitives::ICompositionElement ^ definitionOrigin);
public AssemblyCatalog(string codeBase, System.ComponentModel.Composition.Primitives.ICompositionElement definitionOrigin);
new System.ComponentModel.Composition.Hosting.AssemblyCatalog : string * System.ComponentModel.Composition.Primitives.ICompositionElement -> System.ComponentModel.Composition.Hosting.AssemblyCatalog
Public Sub New (codeBase As String, definitionOrigin As ICompositionElement)
參數
- codeBase
- String
一個字串,指定組合語言的程式碼基底(即通往組合語言檔案的路徑),其中包含要加入AssemblyCatalog物件的屬性Type物件。
- definitionOrigin
- ICompositionElement
診斷用來辨識零件來源的元件。
例外狀況
呼叫者沒有路徑發現權限。
codeBase 或 definitionOrigin 為 null。
找不到 codeBase。
codeBase 是零長度字串,僅包含空白,或包含一個或多個無效字元,定義如下 InvalidPathChars。
指定的路徑、檔名或兩者都超過系統定義的最大長度。
備註
所參考的 codeBase 組裝件會被載入到 Load 上下文中。
適用於
AssemblyCatalog(String, ReflectionContext)
初始化一個以指定的程式碼庫和反射上下文的新類別實例 AssemblyCatalog 。
public:
AssemblyCatalog(System::String ^ codeBase, System::Reflection::ReflectionContext ^ reflectionContext);
public AssemblyCatalog(string codeBase, System.Reflection.ReflectionContext reflectionContext);
new System.ComponentModel.Composition.Hosting.AssemblyCatalog : string * System.Reflection.ReflectionContext -> System.ComponentModel.Composition.Hosting.AssemblyCatalog
Public Sub New (codeBase As String, reflectionContext As ReflectionContext)
參數
- codeBase
- String
一個字串,指定組合語言的程式碼基底(即通往組合語言檔案的路徑),其中包含要加入AssemblyCatalog物件的屬性Type物件。
- reflectionContext
- ReflectionContext
目錄用來解釋類型時所使用的脈絡。
例外狀況
呼叫者沒有路徑發現權限。
codeBase 或 reflectionContext 為 null。
找不到 codeBase。
codeBase 是零長度字串,僅包含空白,或包含一個或多個無效字元,定義如下 InvalidPathChars。
指定的路徑、檔名或兩者都超過系統定義的最大長度。
備註
所參考的codebase 組裝件會被載入到 Load 上下文中。
適用於
AssemblyCatalog(Assembly, ReflectionContext, ICompositionElement)
初始化一個以指定的組合語言與反射上下文的新類別實例 AssemblyCatalog 。
public:
AssemblyCatalog(System::Reflection::Assembly ^ assembly, System::Reflection::ReflectionContext ^ reflectionContext, System::ComponentModel::Composition::Primitives::ICompositionElement ^ definitionOrigin);
public AssemblyCatalog(System.Reflection.Assembly assembly, System.Reflection.ReflectionContext reflectionContext, System.ComponentModel.Composition.Primitives.ICompositionElement definitionOrigin);
new System.ComponentModel.Composition.Hosting.AssemblyCatalog : System.Reflection.Assembly * System.Reflection.ReflectionContext * System.ComponentModel.Composition.Primitives.ICompositionElement -> System.ComponentModel.Composition.Hosting.AssemblyCatalog
Public Sub New (assembly As Assembly, reflectionContext As ReflectionContext, definitionOrigin As ICompositionElement)
參數
- assembly
- Assembly
包含 Type 要加入 AssemblyCatalog 物件的屬性物件的組合語言。
- reflectionContext
- ReflectionContext
目錄用來解釋類型時所使用的脈絡。
- definitionOrigin
- ICompositionElement
診斷用來辨識零件來源的元件。
例外狀況
適用於
AssemblyCatalog(String, ReflectionContext, ICompositionElement)
初始化一個以指定的程式碼庫和反射上下文的新類別實例 AssemblyCatalog 。
public:
AssemblyCatalog(System::String ^ codeBase, System::Reflection::ReflectionContext ^ reflectionContext, System::ComponentModel::Composition::Primitives::ICompositionElement ^ definitionOrigin);
public AssemblyCatalog(string codeBase, System.Reflection.ReflectionContext reflectionContext, System.ComponentModel.Composition.Primitives.ICompositionElement definitionOrigin);
new System.ComponentModel.Composition.Hosting.AssemblyCatalog : string * System.Reflection.ReflectionContext * System.ComponentModel.Composition.Primitives.ICompositionElement -> System.ComponentModel.Composition.Hosting.AssemblyCatalog
Public Sub New (codeBase As String, reflectionContext As ReflectionContext, definitionOrigin As ICompositionElement)
參數
- codeBase
- String
一個字串,指定組合語言的程式碼基底(即通往組合語言檔案的路徑),其中包含要加入AssemblyCatalog物件的屬性Type物件。
- reflectionContext
- ReflectionContext
目錄用來解釋類型時所使用的脈絡。
- definitionOrigin
- ICompositionElement
診斷用來辨識零件來源的元件。
例外狀況
呼叫者沒有路徑發現權限。
codeBase,definitionOrigin或reflectionContext是。null
找不到 codeBase。
codeBase 是零長度字串,僅包含空白,或包含一個或多個無效字元,定義如下 InvalidPathChars。
指定的路徑、檔名或兩者都超過系統定義的最大長度。
備註
所參考的 codebase 組裝件會被載入到 Load 上下文中。