Share via


JSMethodInfo.IsDefined(Type, Boolean) 方法

定义

确定指定的特性类型是否附加到此方法。

此 API 支持产品基础结构,不能在代码中直接使用。

public:
 override bool IsDefined(Type ^ type, bool inherit);
public override sealed bool IsDefined (Type type, bool inherit);
override this.IsDefined : Type * bool -> bool
Public Overrides NotOverridable Function IsDefined (type As Type, inherit As Boolean) As Boolean

参数

type
Type

要搜索的特性类型。

inherit
Boolean

如果为 true,则搜索此成员的继承层次结构以查找特性。

返回

如果指定特性 type 的一个或多个实例附加到此方法,则为 true;否则为 false

适用于

另请参阅