public static T GetCustomAttribute <T>(this IPropertyDescriptor me, bool inherit = true) where T : Attribute { var attributes = me.GetCustomAttributes(typeof(T), inherit); if (attributes == null || attributes.Length == 0) { return(null); } return((T)attributes[0]); }
public T[] GetCustomAttributes <T>(bool inherit = true) where T : Attribute { return(holder.GetCustomAttributes <T>(inherit)); }