Exemple #1
0
 static bool IsValid(IPropertyDescriptor p)
 {
     if (p == null)
     {
         return(false);
     }
     if (p.IsDefined <NoApi>())
     {
         return(false);
     }
     // we dont want many to many realationship tables, it didnt work anyway, lets be explicit with NoApi
     //if (typeof(ICollection<>).IsAssignableFrom(p.Type)) return false;
     //if (typeof(ICollection).IsAssignableFrom(p.Type)) return false;
     return(true);
 }
Exemple #2
0
 public static bool IsDefined <T>(this IPropertyDescriptor me, bool inherit = true) where T : Attribute
 {
     return(me.IsDefined(typeof(T)));
 }
Exemple #3
0
 public bool IsDefined(Type attributeType, bool inherit = true)
 {
     return(holder.IsDefined(attributeType, inherit));
 }