src/Mimp.SeeSharper.Reflection/TypeExtensions.Attribute.cs
/// <summary>
/// Check if <paramref name="type"/> has at least one attribute of <typeparamref name="TAttribute"/>.
/// </summary>
/// <param name="type"></param>
/// <param name="inherit"></param>
/// <returns></returns>
/// <exception cref="ArgumentNullException"></exception>
Check if  has at least one attribute of .
Check if has at least one attribute of .
public static bool HasCustomAttribute<TAttribute>(this Type type, bool inherit)
            where TAttribute : Attribute
        {
            if (type is null)
                throw new ArgumentNullException(nameof(type));
            return type.HasCustomAttribute(typeof(TAttribute), inherit);
        }
public static bool HasCustomAttribute < TAttribute > ( this Type type , bool inherit ) where TAttribute : Attribute { if ( type is null ) throw new ArgumentNullException ( nameof ( type ) ) ; return type . HasCustomAttribute ( typeof ( TAttribute ) , inherit ) ; }
Check if  has at least one attribute of .
Check if has at least one attribute of .
None
None
Type
this
inherit
bool
None
type
None