_Type.IsSubclassOf(Type) 方法

定义

为 COM 对象提供对 IsSubclassOf(Type) 方法的与版本无关的访问。Provides COM objects with version-independent access to the IsSubclassOf(Type) method.

public:
 bool IsSubclassOf(Type ^ c);
public bool IsSubclassOf (Type c);
abstract member IsSubclassOf : Type -> bool
Public Function IsSubclassOf (c As Type) As Boolean

参数

c
Type

要与当前的 Type 进行比较的 TypeThe Type to compare with the current Type.

返回

Boolean

如果 Typec 参数表示并且当前的 Type 表示类,并且当前的 Type 所表示的类是从 c 所表示的类派生的,则为 true;否则为 falsetrue if the Type represented by the c parameter and the current Type represent classes, and the class represented by the current Type derives from the class represented by c; otherwise, false. 如果 c 和当前的 Type 表示相同的类,则此方法还返回 falseThis method also returns false if c and the current Type represent the same class.

注解

此方法用于从非托管代码访问托管类,不应从托管代码调用。This method is for access to managed classes from unmanaged code, and should not be called from managed code.

Type.IsSubclassOf方法确定当前表示的类是否是 Type 从指定的表示的类派生的 TypeThe Type.IsSubclassOf method determines whether the class represented by the current Type derives from the class represented by the specified Type.

适用于