PropertyDescriptor.GetInvocationTarget(Type, Object) 方法

定義

這個方法會傳回在調用成員期間應該使用的物件。

protected:
 override System::Object ^ GetInvocationTarget(Type ^ type, System::Object ^ instance);
protected override object GetInvocationTarget(Type type, object instance);
override this.GetInvocationTarget : Type * obj -> obj
Protected Overrides Function GetInvocationTarget (type As Type, instance As Object) As Object

參數

type
Type

召喚目標的。Type

instance
Object

潛在的召喚目標。

傳回

Object那個應該在召集成員時使用。

備註

通常,回傳值會與傳入的 instance 相同。 如果有人將其他物件與此實例關聯,或該實例是自訂型別描述符,方法 GetInvocationTarget 可能會回傳不同的值。

適用於