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 搜尋此成員的繼承階層以找到屬性。

傳回

true 如果該方法附加了一個或多個指定屬性 type 的實例;否則, false

適用於

另請參閱