MemberInfo.ICustomAttributeProvider.IsDefined(Type, Boolean) 方法

定義

指出此成員上是否有定義一個或多個 attributeType 執行個體。

 virtual bool System.Reflection.ICustomAttributeProvider.IsDefined(Type ^ attributeType, bool inherit) = System::Reflection::ICustomAttributeProvider::IsDefined;
bool ICustomAttributeProvider.IsDefined (Type attributeType, bool inherit);
abstract member System.Reflection.ICustomAttributeProvider.IsDefined : Type * bool -> bool
override this.System.Reflection.ICustomAttributeProvider.IsDefined : Type * bool -> bool
Function IsDefined (attributeType As Type, inherit As Boolean) As Boolean Implements ICustomAttributeProvider.IsDefined

參數

attributeType
Type

自訂屬性的類型。

inherit
Boolean

true 時,請查閱繼承自訂屬性的階層鏈結。

傳回

Boolean

如果此成員上已定義 attributeType,則為 true,否則為 false

實作

適用於