EnumBuilder.IsDefined(Type, Boolean) 메서드

정의

지정된 사용자 지정 특성 유형이 정의되었는지 확인합니다.

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

매개 변수

attributeType
Type

사용자 지정 특성이 적용되는 Type 개체입니다.

inherit
Boolean

이 멤버의 상속 체인을 검색하여 특성을 찾을지 여부를 지정합니다.

반환

이 멤버에 attributeType 인스턴스가 하나 이상 정의되어 있으면 true이고, 그렇지 않으면 false입니다.

예외

이 메서드는 완전하지 않은 형식에서 현재 지원되지 않습니다.

설명

해결 방법으로 완성된 형식에 대해 사용자 지정 특성이 정의되어 있는지 검사 위해 를 사용하여 GetType 형식을 검색하고 반환Type된 에서 를 호출 GetCustomAttributes 합니다.

적용 대상