FieldBuilder.IsDefined(Type, Boolean) Método

Definição

Indica se um atributo com o tipo especificado está definido num campo.

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

Parâmetros

attributeType
Type

O tipo do atributo.

inherit
Boolean

Controla a herança de atributos personalizados das classes base.

Devoluções

true se uma ou mais instâncias de attributeType forem definidas neste corpo; caso contrário, false.

Exceções

Este método não é atualmente suportado. Recupere o campo usando GetField(String, BindingFlags) e chame IsDefined(Type, Boolean) no retorno FieldInfo.

Aplica-se a