TypeDescriptor.GetReflectionType 方法

定義

回傳 a Type 可用於進行反射。

多載

名稱 Description
GetReflectionType(Object)

回傳 Type 一個可用於在給定物件時進行反射的 a。

GetReflectionType(Type)

回傳 a Type 可用於在給定類別類型時進行反射。

GetReflectionType(Object)

回傳 Type 一個可用於在給定物件時進行反射的 a。

public:
 static Type ^ GetReflectionType(System::Object ^ instance);
public static Type GetReflectionType(object instance);
static member GetReflectionType : obj -> Type
Public Shared Function GetReflectionType (instance As Object) As Type

參數

instance
Object

目標元件的實例。

傳回

Type A 代表指定的物件。

例外狀況

instancenull

備註

GetReflectionType 方法是該方法的 GetTypeDescriptor 低階版本。 GetReflectionType 通常用於在無法找到自訂型別描述符時,對物件進行標準反射。

另請參閱

適用於

GetReflectionType(Type)

回傳 a Type 可用於在給定類別類型時進行反射。

public:
 static Type ^ GetReflectionType(Type ^ type);
public static Type GetReflectionType(Type type);
static member GetReflectionType : Type -> Type
Public Shared Function GetReflectionType (type As Type) As Type

參數

type
Type

目標成分的。Type

傳回

Type A,屬於指定類別。

例外狀況

typenull

備註

GetReflectionType 方法是該方法的 GetTypeDescriptor 低階版本。 GetReflectionType 通常用於在無法找到自訂型別描述符時,對類別進行標準反射。

另請參閱

適用於