public static IsSimpleType ( this type ) : bool | ||
type | this | |
return | bool |
public static bool IsSimpleType(this Type type) {
if(type.IsPrimitive)
return true;
if(IsSameOrSubclassOf(type, typeof(string)))
return true;
if(IsSameOrSubclassOf(type, typeof(DateTime)))
return true;
if(IsSameOrSubclassOf(type, typeof(Decimal)))
return true;
if(IsSameOrSubclassOf(type, typeof(DBNull)))
return true;
return false;
}