Marshal.CreateAggregatedObject 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
多載
CreateAggregatedObject(IntPtr, Object) |
已淘汰.
將 Managed 物件與指定的 COM 物件進行彙總。 |
CreateAggregatedObject<T>(IntPtr, T) |
將所指定類型的 Managed 物件與指定的 COM 物件進行彙總。 |
CreateAggregatedObject(IntPtr, Object)
警告
CreateAggregatedObject(IntPtr, Object) may be unavailable in future releases. Instead, use CreateAggregatedObject<T>(IntPtr, T). For more info, go to http://go.microsoft.com/fwlink/?LinkID=296518
將 Managed 物件與指定的 COM 物件進行彙總。
public:
static IntPtr CreateAggregatedObject(IntPtr pOuter, System::Object ^ o);
[System.Obsolete("CreateAggregatedObject(IntPtr, Object) may be unavailable in future releases. Instead, use CreateAggregatedObject<T>(IntPtr, T). For more info, go to http://go.microsoft.com/fwlink/?LinkID=296518")]
[System.Security.SecurityCritical]
public static IntPtr CreateAggregatedObject (IntPtr pOuter, object o);
[System.Runtime.Versioning.SupportedOSPlatform("windows")]
public static IntPtr CreateAggregatedObject (IntPtr pOuter, object o);
[System.Security.SecurityCritical]
public static IntPtr CreateAggregatedObject (IntPtr pOuter, object o);
public static IntPtr CreateAggregatedObject (IntPtr pOuter, object o);
[<System.Obsolete("CreateAggregatedObject(IntPtr, Object) may be unavailable in future releases. Instead, use CreateAggregatedObject<T>(IntPtr, T). For more info, go to http://go.microsoft.com/fwlink/?LinkID=296518")>]
[<System.Security.SecurityCritical>]
static member CreateAggregatedObject : nativeint * obj -> nativeint
[<System.Runtime.Versioning.SupportedOSPlatform("windows")>]
static member CreateAggregatedObject : nativeint * obj -> nativeint
[<System.Security.SecurityCritical>]
static member CreateAggregatedObject : nativeint * obj -> nativeint
static member CreateAggregatedObject : nativeint * obj -> nativeint
Public Shared Function CreateAggregatedObject (pOuter As IntPtr, o As Object) As IntPtr
參數
- pOuter
-
IntPtr
nativeint
外部 IUnknown
指標。
- o
- Object
要彙總的物件。
傳回
nativeint
受管理物件的內部 IUnknown
指標。
- 屬性
例外狀況
o
是 Windows 執行時間物件。
備註
CreateAggregatedObject方法會使用指定的外部指標來匯總 Managed 對象的內部 Managed 指標,然後傳回 Managed 對象的內部 IUnknown 指標。
適用於
CreateAggregatedObject<T>(IntPtr, T)
將所指定類型的 Managed 物件與指定的 COM 物件進行彙總。
public:
generic <typename T>
static IntPtr CreateAggregatedObject(IntPtr pOuter, T o);
[System.Security.SecurityCritical]
public static IntPtr CreateAggregatedObject<T> (IntPtr pOuter, T o);
[System.Runtime.Versioning.SupportedOSPlatform("windows")]
public static IntPtr CreateAggregatedObject<T> (IntPtr pOuter, T o);
public static IntPtr CreateAggregatedObject<T> (IntPtr pOuter, T o);
[<System.Security.SecurityCritical>]
static member CreateAggregatedObject : nativeint * 'T -> nativeint
[<System.Runtime.Versioning.SupportedOSPlatform("windows")>]
static member CreateAggregatedObject : nativeint * 'T -> nativeint
static member CreateAggregatedObject : nativeint * 'T -> nativeint
Public Shared Function CreateAggregatedObject(Of T) (pOuter As IntPtr, o As T) As IntPtr
類型參數
- T
要彙總的 Managed 物件類型。
參數
- o
- T
要彙總的 Managed 物件。
傳回
nativeint
Managed 物件的內部 IUnknown 指標。
- 屬性
例外狀況
o
是 Windows 執行時間物件。
備註
CreateAggregatedObject方法會匯總具有指定外部指標之指定型別之 Managed 物件的內部 Managed 指標,並傳回 Managed 物件的內部 IUnknown 指標。