Example #1
0
 public static Attribute AttrOrNull(this ICustomAttributeProvider cap, Type t)
 {
     if (cap == null)
     {
         return(null);
     }
     return(cap.AttrOrNull(t, true));
 }
Example #2
0
 public static T AttrOrNull <T>(this ICustomAttributeProvider cap, bool inherit)
     where T : Attribute
 {
     if (cap == null)
     {
         return(null);
     }
     return((T)cap.AttrOrNull(typeof(T), inherit));
 }
Example #3
0
 public static T AttrOrNull <T>(this ICustomAttributeProvider cap)
     where T : Attribute
 {
     return(cap.AttrOrNull <T>(true));
 }